CGameServer::UpdateMasterServerPlayers
0x001fb1d0 · 391 bytes · __thiscall
_ZN11CGameServer25UpdateMasterServerPlayersEv
Decompiled
undefined (1 param)
/* CGameServer::UpdateMasterServerPlayers() */
void __thiscall CGameServer::UpdateMasterServerPlayers(CGameServer *this)
{
byte bVar1;
int *piVar2;
int *piVar3;
undefined4 uVar4;
code *pcVar5;
char cVar6;
int iVar7;
int iVar8;
int iVar9;
undefined4 uVar10;
byte bVar11;
iVar7 = Steam3Server();
if (*(int *)(iVar7 + 4) != 0) {
for (iVar7 = 0; iVar8 = (**(code **)(*(int *)this + 0x20))(this), iVar7 < iVar8;
iVar7 = iVar7 + 1) {
piVar2 = *(int **)(*(int *)(this + 0x114) + iVar7 * 4);
cVar6 = (**(code **)(*piVar2 + 0x6c))(piVar2);
if (((cVar6 != '\0') && (cVar6 = (**(code **)(*piVar2 + 0x80))(piVar2), cVar6 != '\0')) &&
(iVar8 = (**(code **)(*serverGameClients + 0x2c))(serverGameClients,piVar2[0x75d4]),
iVar8 != 0)) {
bVar1 = *(byte *)((int)piVar2 + 0x83);
bVar11 = bVar1 & 0xf0;
if ((((bVar1 & 0xf0) != 0) && (bVar1 < 0xb0)) && ((byte)((char)piVar2[0x21] - 1U) < 4)) {
if (bVar11 == 0x10) {
if ((*(int *)((int)piVar2 + 0x7d) != 0) &&
(((*(byte *)((int)piVar2 + 0x83) & 0xf) << 0x10 |
(uint)*(ushort *)((int)piVar2 + 0x81)) == 1)) goto LAB_001fb27a;
}
else if (bVar11 == 0x70) {
if ((*(int *)((int)piVar2 + 0x7d) != 0) &&
((*(byte *)((int)piVar2 + 0x83) & 0xf) == 0 && *(short *)((int)piVar2 + 0x81) == 0))
goto LAB_001fb27a;
}
else if ((bVar11 != 0x30) || (*(int *)((int)piVar2 + 0x7d) != 0)) {
LAB_001fb27a:
iVar9 = Steam3Server();
piVar3 = *(int **)(iVar9 + 4);
uVar4 = *(undefined4 *)(iVar8 + 0x2c);
pcVar5 = *(code **)(*piVar3 + 0xa4);
uVar10 = (**(code **)(*piVar2 + 0x1c))(piVar2);
(*pcVar5)(piVar3,*(undefined4 *)((int)piVar2 + 0x7d),*(undefined4 *)((int)piVar2 + 0x81)
,uVar10,uVar4);
}
}
}
}
}
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.