413 B
413 B
Basalt
onEvent
This is the top-level method to intercept an event before sending it to the object event handlers. If you use return false, the event is not passed to the event handlers.
Parameters
functionThe function which should be called
Usage
local basalt = require("basalt")
basalt.onEvent(function(event)
if(event=="terminate")then
return false
end
end)