CSceneManager::IsRunningScriptedSceneWithSpeech
0x00814740 · 238 bytes · __thiscall
_ZN13CSceneManager32IsRunningScriptedSceneWithSpeechEP9CBaseFlexb
Decompiled
undefined (3 params)
/* CSceneManager::IsRunningScriptedSceneWithSpeech(CBaseFlex*, bool) */
undefined4 __thiscall
CSceneManager::IsRunningScriptedSceneWithSpeech(CSceneManager *this,CBaseFlex *param_1,bool param_2)
{
int iVar1;
uint uVar2;
CSceneEntity *this_00;
char cVar3;
int iVar4;
undefined4 uVar5;
undefined *puVar6;
int iVar7;
iVar7 = 0;
iVar1 = *(int *)(this + 0x44c);
if (0 < iVar1) {
do {
uVar2 = *(uint *)(*(int *)(this + 0x440) + iVar7 * 4);
if ((((((uVar2 != 0xffffffff) &&
(puVar6 = g_pEntityList + (uVar2 & 0xfff) * 0x10, puVar6 != (undefined *)0xfffffffc))
&& (*(uint *)(puVar6 + 8) == uVar2 >> 0xc)) &&
((this_00 = *(CSceneEntity **)(puVar6 + 4), this_00 != (CSceneEntity *)0x0 &&
(this_00[0x494] != (CSceneEntity)0x0)))) &&
((!param_2 ||
(iVar4 = __dynamic_cast(this_00,&CSceneEntity::typeinfo,&CInstancedSceneEntity::typeinfo,
0), iVar4 == 0)))) &&
(((cVar3 = CSceneEntity::InvolvesActor(this_00,(CBaseEntity *)param_1), cVar3 != '\0' &&
(*(CChoreoScene **)(this_00 + 0x4f0) != (CChoreoScene *)0x0)) &&
(uVar5 = CChoreoScene::HasUnplayedSpeech(*(CChoreoScene **)(this_00 + 0x4f0)),
(char)uVar5 != '\0')))) {
return uVar5;
}
iVar7 = iVar7 + 1;
} while (iVar7 != iVar1);
}
return 0;
}
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.