allow dispatching events from lua