UEScriptSignal - notreux/UpsideEngine GitHub Wiki
Constructor
UEScriptSignal object:on(string eventName, function callback=nil)
Method to UEScriptSignal creation
Methods
void disconnect()
Disconnects the callback to the event
any wait()
Yields until event fired and returns the parameters
Examples
local connection
connection = object:on("changed", function(property)
print(property, ("was changed!, new %s: %s"):format(property, object[property]))
connection:disconnect()
end)
local property = object:on("changed"):wait()
-- yields until a property of the object is changed
print(property, ("was changed!, new %s: %s"):format(property, object[property]))