CVScriptGameEventListener::CollectGameEventCallbacksInScope
0x00b47620 · 188 bytes · __thiscall
_ZN25CVScriptGameEventListener32CollectGameEventCallbacksInScopeEP9HSCRIPT__
Decompiled
undefined (2 params)
/* CVScriptGameEventListener::CollectGameEventCallbacksInScope(HSCRIPT__*) */
void __thiscall
CVScriptGameEventListener::CollectGameEventCallbacksInScope
(CVScriptGameEventListener *this,HSCRIPT__ *param_1)
{
int iVar1;
HSCRIPT__ *local_18;
undefined4 local_14;
undefined2 local_10;
ushort local_e;
iVar1 = *(int *)(this + 0x10);
if (iVar1 == -1) {
iVar1 = (**(code **)(*g_pScriptVM + 0x48))(g_pScriptVM,"__CollectGameEventCallbacks",0,0);
*(int *)(this + 0x10) = iVar1;
}
if (iVar1 != 0) {
local_e = 0;
local_10 = 0x20;
local_14 = 0;
local_18 = param_1;
/* try { // try from 00b4768d to 00b4768f has its CatchHandler @ 00b476e5 */
(**(code **)(*g_pScriptVM + 0x50))(g_pScriptVM,iVar1,&local_18,1,0,0,1);
if ((local_e & 1) != 0) {
free(local_18);
return;
}
}
return;
}
SourceMod gamedata
paste intoaddons/sourcemod/gamedata/<your_plugin>.txt
used as the SourceMod key — change to fit your plugin's convention
SourceMod library name (server / engine / matchmaking)
Just a Signatures{} block, ready to drop into a gamedata
file. Wire it up in your plugin however you like - SDKCall, DHooks,
raw memory ops, or anything else.
Signatures + Functions block. The plugin uses
DHookCreateFromConf - DHooks reads return type, this-type,
calling convention, and argument types straight from the gamedata. Less
boilerplate in the plugin, types travel with the gamedata.
Gamedata KeyValues
DHooks plugin example
Type inference is best-effort from the C signature - sanity-check the DHooks types before shipping.