CAI_Expresser::ForceNotSpeaking
0x005d1830 · 259 bytes · __thiscall
_ZN13CAI_Expresser16ForceNotSpeakingEv
Decompiled
undefined (1 param)
/* CAI_Expresser::ForceNotSpeaking() */
void __thiscall CAI_Expresser::ForceNotSpeaking(CAI_Expresser *this)
{
uint uVar1;
char cVar2;
undefined4 *puVar3;
undefined *puVar4;
int iVar5;
int local_20;
cVar2 = (**(code **)(*(int *)this + 0x10))(this);
iVar5 = gpGlobals;
if (cVar2 != '\0') {
*(undefined4 *)(this + 0x2c) = *(undefined4 *)(gpGlobals + 0xc);
*(undefined4 *)(this + 0x30) = *(undefined4 *)(iVar5 + 0xc);
puVar3 = (undefined4 *)GetMySpeechSemaphore((CBaseEntity *)this);
if (puVar3 != (undefined4 *)0x0) {
uVar1 = puVar3[1];
local_20 = 0;
if (((uVar1 != 0xffffffff) &&
(puVar4 = g_pEntityList + (uVar1 & 0xfff) * 0x10, puVar4 != (undefined *)0xfffffffc)) &&
(*(uint *)(puVar4 + 8) == uVar1 >> 0xc)) {
local_20 = *(int *)(puVar4 + 4);
}
uVar1 = *(uint *)(this + 0x40);
iVar5 = 0;
if (((uVar1 != 0xffffffff) &&
(puVar4 = g_pEntityList + (uVar1 & 0xfff) * 0x10, puVar4 != (undefined *)0xfffffffc)) &&
(*(uint *)(puVar4 + 8) == uVar1 >> 0xc)) {
iVar5 = *(int *)(puVar4 + 4);
}
if (local_20 == iVar5) {
*puVar3 = 0;
puVar3[1] = 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.