CBasePlayer::PrepareForFullUpdate
0x007b8df0 · 146 bytes · __thiscall
_ZN11CBasePlayer20PrepareForFullUpdateEv
Decompiled
undefined (1 param)
/* CBasePlayer::PrepareForFullUpdate() */
void __thiscall CBasePlayer::PrepareForFullUpdate(CBasePlayer *this)
{
float fVar1;
CBaseEntity *pCVar2;
char cVar3;
uint uVar4;
if (this[0x2348] != (CBasePlayer)0x0) {
this[0x2348] = (CBasePlayer)0x0;
if (*(int *)(this + 0x30) == 0) {
cVar3 = '\0';
}
else {
cVar3 = (char)(*(int *)(this + 0x30) - *(int *)(gpGlobals + 0x58) >> 4);
}
pCVar2 = (CBaseEntity *)0x0;
uVar4 = 1 << (cVar3 - 1U & 0x1f);
while( true ) {
pCVar2 = (CBaseEntity *)CGlobalEntityList::NextEnt((CGlobalEntityList *)gEntList,pCVar2);
if (pCVar2 == (CBaseEntity *)0x0) break;
if ((*(uint *)(pCVar2 + 0x78) & uVar4) != 0) {
*(uint *)(pCVar2 + 0x78) = *(uint *)(pCVar2 + 0x78) & ~uVar4;
}
}
fVar1 = *(float *)(gpGlobals + 0xc);
*(undefined4 *)(this + 0x2340) = 0;
*(float *)(this + 0x233c) = fVar1 + 2.5;
}
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.