L L4D2node

CServerRemoteAccess::GetStatsString

0x0020eea0 · 272 bytes · __thiscall

_ZN19CServerRemoteAccess14GetStatsStringEPci

Decompiled

undefined (3 params)

/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
/* CServerRemoteAccess::GetStatsString(char*, int) */

void __thiscall
CServerRemoteAccess::GetStatsString(CServerRemoteAccess *this,char *param_1,int param_2)

{
  int iVar1;
  int iVar2;
  int iVar3;
  longdouble lVar4;
  double dVar5;
  float local_24;
  float local_20 [4];
  
  local_24 = 0.0;
  local_20[0] = 0.0;
  CBaseServer::GetNetStats((CBaseServer *)&sv,&local_24,local_20);
  iVar2 = CBaseServer::GetNumClients((CBaseServer *)&sv);
  iVar3 = CBaseServer::GetNumProxies((CBaseServer *)&sv);
  dVar5 = (double)host_frametime;
  iVar1 = DAT_003b8068 + -1;
  lVar4 = (longdouble)Plat_FloatTime();
  snprintf(param_1,param_2 - 1,"%5.2f %5.2f %5.2f %7i %5i %7.2f %7i",(double)(_DAT_003b80a0 * 100.0)
           ,(double)local_24,(double)local_20[0],(int)lVar4 / 0x3c,iVar1,1.0 / dVar5,iVar2 - iVar3);
  param_1[param_2 + -1] = '\0';
  return;
}

SourceMod gamedata

paste into addons/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.



        

        

          

Type inference is best-effort from the C signature - sanity-check the DHooks types before shipping.

Return-type handling cheatsheet (DHookReturn)