CScriptResponseCriteria::GetTable
0x00b45130 · 221 bytes · __thiscall
_ZN23CScriptResponseCriteria8GetTableEP9HSCRIPT__S1_
Decompiled
undefined (3 params)
/* CScriptResponseCriteria::GetTable(HSCRIPT__*, HSCRIPT__*) */
void __thiscall
CScriptResponseCriteria::GetTable
(CScriptResponseCriteria *this,HSCRIPT__ *param_1,HSCRIPT__ *param_2)
{
code *pcVar1;
ScriptClassDesc_t *pSVar2;
int *piVar3;
undefined4 uVar4;
undefined4 uVar5;
int iVar6;
int iVar7;
AI_CriteriaSet local_3c [18];
short local_2a;
if (param_1 != (HSCRIPT__ *)0x0) {
pcVar1 = *(code **)(*g_pScriptVM + 0x68);
pSVar2 = GetScriptDesc<CBaseEntity>((CBaseEntity *)0x0);
piVar3 = (int *)(*pcVar1)(g_pScriptVM,param_1,pSVar2);
if ((piVar3 != (int *)0x0) && (param_2 != (HSCRIPT__ *)0x0)) {
AI_CriteriaSet::AI_CriteriaSet(local_3c);
/* try { // try from 00b45199 to 00b45201 has its CatchHandler @ 00b45216 */
(**(code **)(*piVar3 + 0x200))(piVar3,local_3c);
iVar7 = 0;
while( true ) {
iVar6 = AI_CriteriaSet::GetCount(local_3c);
if (iVar6 <= iVar7) break;
if ((-1 < iVar7) && (iVar7 < local_2a)) {
pcVar1 = *(code **)(*g_pScriptVM + 0x74);
uVar4 = AI_CriteriaSet::GetValue(local_3c,iVar7);
uVar5 = AI_CriteriaSet::GetName(local_3c,iVar7);
(*pcVar1)(g_pScriptVM,param_2,uVar5,uVar4);
}
iVar7 = iVar7 + 1;
}
AI_CriteriaSet::~AI_CriteriaSet(local_3c);
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.