EventHook TypeSet

Hook function types for events.

function Action(Event event, const char[] name, bool dontBroadcast)

Called when a game event is fired.

Parameters

event

Handle to event. This could be INVALID_HANDLE if every plugin hooking this event has set the hook mode EventHookMode_PostNoCopy.

name

String containing the name of the event.

dontBroadcast

True if event was not broadcast to clients, false otherwise.

return

Ignored for post hooks. Plugin_Handled will block event if hooked as pre.

function void(Event event, const char[] name, bool dontBroadcast)

Called when a game event is fired.

Parameters

event

Handle to event. This could be INVALID_HANDLE if every plugin hooking this event has set the hook mode EventHookMode_PostNoCopy.

name

String containing the name of the event.

dontBroadcast

True if event was not broadcast to clients, false otherwise.