GlobalVariable Script

Extends: Form Script

Script for the manipulation of global variable objects.

DefinitionEdit

ScriptName GlobalVariable extends Form

PropertiesEdit

  • float Value [read-write]: The current value of this global variable object.

Global FunctionsEdit

None

Member FunctionsEdit

Float GetValue()
  • Returns this global variable's current value.
Int GetValueInt()
  • Returns this global variable's current value cast as an int.
Float Mod(Float afHowMuch)
  • Modifies this global variable's value in a more thread-safe way.
SetValue(Float afNewValue)
  • Sets this global variable's current value.
SetValueInt(Int aiNewValue)
  • Sets this global variable's current value to the specified int.

NotesEdit

  • For SetValueInt(), and GetValueInt(), it is better and faster to use traditional cast methods. As is the compiler will auto-cast them which is slower. Use GetValue() as int, and SetValue(MyInt as float) instead.

EventsEdit

None