Commands
Variables (12)

abs Value

Categories: variables, return
Returns the absolute value of a variable - meaning: the number turns positive

freevar "Variable" ... [,"Variable"]

Categories: variables, free
Deletes one or more variables

freevars [Locals]

Categories: variables, free
Deletes all variables. The parameter Locals allows you to choose wether the local variables shall be deleted too (standard value: 1)

getlocal "Class", ID, "Variable"

Categories: variables, return
Gets the value of a certain local variable at a certain object. This allows to access local variables from other objects.

loadvars ["File"]

Categories: variables, return
Loads all variables from a file that has been saved before per savevars command (standard destination: "varcache" in the mod folder).
Afterwards, the variables are available again as normal global variables - just like before

local "Variable" ... [,"Variable"]

Categories: variables
Makes one or more variables local. You can only access local variables from the object where the script is executed.
The variables will be created and set to 0 if they don't exist already.

rename "Variable" "Name"

Categories: variables
Changes the name of a variable

savevars ["File"] [, "Variables"]

Categories: variables, return
Saves all global variables in a file (standard destination: "varcache" in the mod folder). If File is filled in, the values will be saved to the particular name instead.
By standard, ALL global variables will be saved. Alternatively, you can name variables by the parameter Variables (seperated by commas). In this case, only the desired variables will be saved.
Depending on wether the process was successful, the parameter will return 1 or 0. Per loadvars command the variables can be loaded again

setlocal "Class", ID, "Variable" [,Value]

Categories: variables
Sets or changes the value of a certain local variable at a certain object. This allows to access local variables from other objects. Value is 0 by default.

temp "Variable" ... [,"Variable"]

Categories: variables
Marks one or more variables as temporary. Temporary variables will not be saved with savegames.

tempall

Categories: variables
Marks all variables as temporary. Temporary variables will not be saved with savegames.

varexists "Variable"

Categories: variables, return
Checks wether the specified variable does exist or not, and accordingly returns either 1 or 0

Stranded I, Stranded II & Stranded III are games by Unreal Software 2003-2017 | Contact | Disclaimer