CCSGameRules::NeededPlayersCheck
0x00434920 · 223 bytes · __thiscall
_ZN12CCSGameRules18NeededPlayersCheckERb
Decompiled
undefined (2 params)
/* CCSGameRules::NeededPlayersCheck(bool&) */
undefined4 __thiscall CCSGameRules::NeededPlayersCheck(CCSGameRules *this,bool *param_1)
{
if ((*(int *)(this + 0x274) == 0) || (*(int *)(this + 0x278) == 0)) {
Msg("Game will not start until both teams have players.\n");
UTIL_ClientPrintAll(2,"#Game_scoring",(char *)0x0,(char *)0x0,(char *)0x0,(char *)0x0);
*param_1 = true;
this[0x27c] = (CCSGameRules)0x0;
if (*(int *)(this + 0x274) == 0) {
return 0;
}
}
else if (this[0x27c] != (CCSGameRules)0x0) {
return 0;
}
if (*(int *)(this + 0x278) == 0) {
return 0;
}
if (this[0x23d] != (CCSGameRules)0x0) {
CGameRulesProxy::NotifyNetworkStateChanged();
this[0x23d] = (CCSGameRules)0x0;
}
this[0x27d] = (CCSGameRules)0x1;
(**(code **)(*(int *)this + 0x2a4))(this,0x40400000,0x10);
this[0x27c] = (CCSGameRules)0x1;
return 1;
}
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.