SndPlayInOut
0x008e8e10 · 188 bytes · __cdecl
_Z12SndPlayInOutRK8CCommand
Decompiled
undefined (1 param)
/* SndPlayInOut(CCommand const&) */
void SndPlayInOut(CCommand *param_1)
{
code *pcVar1;
char cVar2;
CBaseEntity *this;
int iVar3;
char *__nptr;
long lVar4;
undefined1 *puVar5;
undefined1 *puVar6;
this = (CBaseEntity *)UTIL_GetCommandClient();
if (this == (CBaseEntity *)0x0) {
return;
}
cVar2 = (**(code **)(*(int *)this + 0x16c))(this);
if (cVar2 == '\0') {
return;
}
cVar2 = (**(code **)(*(int *)this + 300))(this);
if (cVar2 == '\0') {
return;
}
iVar3 = CBaseEntity::GetTeamNumber(this);
if (iVar3 != 2) {
return;
}
pcVar1 = *(code **)(*(int *)(this + 0x3ab4) + 0x154);
__nptr = "";
if (3 < *(int *)param_1) {
__nptr = *(char **)(param_1 + 0x414);
}
lVar4 = strtol(__nptr,(char **)0x0,10);
if (*(int *)param_1 < 3) {
puVar5 = &DAT_00d539c2;
if (*(int *)param_1 != 2) {
puVar6 = &DAT_00d539c2;
goto LAB_008e8eb0;
}
}
else {
puVar5 = *(undefined1 **)(param_1 + 0x410);
}
puVar6 = *(undefined1 **)(param_1 + 0x40c);
LAB_008e8eb0:
(*pcVar1)(this + 0x3ab4,puVar6,puVar5,lVar4);
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.