Get your own free workspace
View
 

Global

Page history last edited by Gamemaster 3 years, 11 months ago

 

Global

Usage:

                Global(ID)

Description:

The Global command returns the value of a given global variable. IDs range from 0 to 99. Globals are local to each script and their values are lost when the script ends or the server is shut down. They are useful for variables which should be shared between all functions in a script. Note that they are not shared between multiple instances of the same script.

Example:

                Function Main()
                        SetGlobal(25, 5)
                        Result = Global(25)
                        Output(Actor(), Result) // Displays 5
                        Return()
                End Function

Comments (0)

You don't have permission to comment on this page.