CDirectorChallengeMode::TermScripts
0x008991b0 · 661 bytes · __thiscall
_ZN22CDirectorChallengeMode11TermScriptsEv
Decompiled
undefined (1 param)
/* CDirectorChallengeMode::TermScripts() */
void __thiscall CDirectorChallengeMode::TermScripts(CDirectorChallengeMode *this)
{
int iVar1;
int iVar2;
iVar1 = TheDirector;
*(undefined4 *)(this + 0x144) = 0;
*(undefined4 *)(this + 0x140) = 0;
if (*(int *)(iVar1 + 0x4b8) != -1) {
iVar2 = (**(code **)(*g_pScriptVM + 0x48))(g_pScriptVM,"Reset",*(int *)(iVar1 + 0x4b8),0);
(**(code **)(*g_pScriptVM + 0x4c))(g_pScriptVM,iVar2);
iVar1 = TheDirector;
if ((iVar2 != 0) &&
(iVar2 = (**(code **)(*g_pScriptVM + 0x48))
(g_pScriptVM,"Reset",*(undefined4 *)(TheDirector + 0x4b8),0), iVar2 != 0))
{
(**(code **)(*g_pScriptVM + 0x50))(g_pScriptVM,iVar2,0,0,0,*(undefined4 *)(iVar1 + 0x4b8),1);
(**(code **)(*g_pScriptVM + 0x4c))(g_pScriptVM,iVar2);
}
}
CScriptHud::TermScripts((CScriptHud *)(this + 0x15c));
if (g_pScriptVM != (int *)0x0) {
if (*(int *)(this + 0x110) - 1U < 0xfffffffe) {
(**(code **)(*g_pScriptVM + 0x4c))(g_pScriptVM,*(int *)(this + 0x110));
iVar1 = *(int *)(this + 0x118);
*(undefined4 *)(this + 0x110) = 0xffffffff;
}
else {
iVar1 = *(int *)(this + 0x118);
}
if (iVar1 - 1U < 0xfffffffe) {
(**(code **)(*g_pScriptVM + 0x4c))(g_pScriptVM,iVar1);
iVar1 = *(int *)(this + 0x11c);
*(undefined4 *)(this + 0x118) = 0xffffffff;
}
else {
iVar1 = *(int *)(this + 0x11c);
}
if (iVar1 - 1U < 0xfffffffe) {
(**(code **)(*g_pScriptVM + 0x4c))(g_pScriptVM,iVar1);
*(undefined4 *)(this + 0x11c) = 0xffffffff;
}
if (*(int *)(this + 0x124) - 1U < 0xfffffffe) {
(**(code **)(*g_pScriptVM + 0x4c))(g_pScriptVM,*(int *)(this + 0x124));
*(undefined4 *)(this + 0x124) = 0xffffffff;
}
if (*(int *)(this + 0x130) - 1U < 0xfffffffe) {
(**(code **)(*g_pScriptVM + 0x4c))(g_pScriptVM,*(int *)(this + 0x130));
iVar1 = *(int *)(this + 0x134);
*(undefined4 *)(this + 0x130) = 0xffffffff;
}
else {
iVar1 = *(int *)(this + 0x134);
}
if (iVar1 - 1U < 0xfffffffe) {
(**(code **)(*g_pScriptVM + 0x4c))(g_pScriptVM,iVar1);
*(undefined4 *)(this + 0x134) = 0xffffffff;
}
if (*(int *)(this + 0x120) - 1U < 0xfffffffe) {
(**(code **)(*g_pScriptVM + 0x44))(g_pScriptVM,*(int *)(this + 0x120));
*(undefined4 *)(this + 0x120) = 0xffffffff;
}
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.