Global||doc136275

September 20, 2022

Global

Global singleton object

Brief Introduction

Global variable Global is a table provided to developers. To define global variables, developers can put the global variables they want to define in this table.

Code Example

Define a global integer variable that can be accessed in every script.

-- script_1
Global.testValue = 1

-- script_2
print(Global.testValue)