GameObject.SendMessage(string methodName, any value = nil)
Calls the method named methodName on every lua script in this game object.
Parameters:
Name | Type | Description |
---|---|---|
methodName | string | The name of the method to call. |
value | any | An optional parameter value to pass to the called method. |
Usage
---@type GameObject
local gameobject;
---@type string
local methodName;
---@type any
local value;
gameobject.SendMessage(methodName, value)