Engine:CCMD set

Console commands

Creates and sets a variable in the current context.

set bob fred

ArgumentsEdit

  • name - name for variable to set
  • value (optional) - the value to set. If no value, then prints value if exists.

DetailsEdit

Can be used to set values for variables. Will create a new variable is not exists.

ExamplesEdit

Default valuesEdit

  • 'set' called with 'bob' without a value. Variable 'bob' doesn't exist.
> set bob
Unknown: bob
  • Creates variable 'bob' and sets to 'fred'.
> set bob fred
  • Same as the first example, but now bob exists.
> var bob
'bob' is 'fred'
  • Try to set existing 'bob' to 'james', value changes.
> var bob james
> var bob
'bob' is 'james'

NotesEdit