GlobalState
API Documentation for GlobalState class
.new()
function.Functions
Seek(VariableName)
The Seek
function is used to get a global variable stored. The VariableName
should be a string value! It will return a nil
value if no global variable by that name is given. An example can be:
SeekFunction(ScriptName, FunctionName)
The SeekFunction
takes 2 variables which of both need to be strings. The function is used to run a function from 1 script to another. Here is an example!
Push(VariableName, VariableValue, Overwrite = true)
The Push
functions takes 2 variables in which VariableName
must be a string and VariableValue
can be of any. It also takes a 3rd optional variable which must be a boolean! The function is used to create/update a global variable. An example can be:
Pop(VariableName)
The Pop
function takes a variable which must be a string and be a value. It returns a bool value to tell if the action was successful or not. An example can be:
ClearGlobalStateMemory()
The ClearGlobalStateMemory
function clears all of the GlobalVariables stored.