Access
All event C++ functions are exposed to your Lua script via a single global table namedevent
. You access individual values by using the dot (.
) or bracket ([]
) operator on this table.
Event Usage Example
Functions
This section lists all available C++ functions exposed within the globalevent
table. These functions are used to manage the registration and execution of Lua functions (callbacks) in response to specific module or game triggers.
set
Registers a Lua function (callback) to be executed whenever a specified event is triggered. Returns a boolean indicating the success of the registration.The event to register the callback for. This can be either a numeric value from the EventType enumeration (e.g.,
EventType.Draw
) or its corresponding string name (e.g., "Draw"
).The Lua function to be executed when the specified event fires.