EventPriority
Priority levels that control listener dispatch order within an event.
Definition EventTypes.h:19
int32_t EventID
Numeric identifier for an event. -1 is uninitialized, IDs < -1 are internally registered,...
Definition EventTypes.h:8
void(* EventCallback)(IEvent *)
Callback signature for event listeners. The argument is the event payload cast to IEvent*.
Definition EventTypes.h:39
int64_t ListenerID
Numeric identifier for a registered listener; used to unregister later.
Definition EventTypes.h:10
Action specialization for event-driven dispatch.
Definition EventAction.h:46
Tickable event bus that dispatches listeners through Tick(EventID).
Definition Events.h:74
Event-bus listener action executed by Events::Tick(EventID).
Definition ListenerAction.h:22
const EventMetadata & GetMetadata() const
Returns the registration-site metadata recorded for this listener.
uint64_t GetSequence() const
Returns the stable registration-order sequence number.
bool ActionRan() override
Executes the listener callback against the current Events payload.
EventPriority GetPriority() const
Returns the dispatch priority used for ordering listeners.
ListenerAction(EventID eventId, ListenerID listenerId, EventPriority priority, uint64_t sequence, Events *events, std::shared_ptr< Tickable > tickable, EventCallback callback, EventMetadata metadata={ nullptr, 0, 0 })
Constructs a listener action for a single EventID.
ListenerID GetListenerId() const
Returns the event-scoped ListenerID for this action.
Core namespace for the libultraship engine framework.
Definition gfx_direct3d_common.h:14