A sequencing class to control the order in which objects are exposed to Lua.
void uLua.LuaExposeSequencer.AddExposeInstruction |
( |
ExposeTarget |
exposeTarget, |
|
|
MonoBehaviour |
targetMonoBehaviour, |
|
|
string |
luaName, |
|
|
LuaMonoBehaviour |
luaParent = null , |
|
|
bool |
enableObjectScript = false |
|
) |
| |
|
inline |
Adds an expose instruction to the sequencer.
- Parameters
-
exposeTarget | The target event to expose the MonoBehaviour on. |
targetMonoBehaviour | The MonoBehaviour to expose. |
luaName | The Lua name to expose the MonoBehaviour as. |
luaParent | The Lua parent of the MonoBehaviour, if any. |
enableObjectScript | If true, the object script will be enabled after exposure. |
This method allows you to queue up MonoBehaviours to be exposed to Lua at specific points in the Unity lifecycle. The exposeTarget
parameter determines when the MonoBehaviour will be exposed (e.g., Awake, Start, OnEnable, SceneLoaded).