L L4D2node

CGlobalState::DumpGlobals

0x006d6c10 · 190 bytes · __thiscall

_ZN12CGlobalState11DumpGlobalsEv

Decompiled

undefined (1 param)

/* CGlobalState::DumpGlobals() */

void __thiscall CGlobalState::DumpGlobals(CGlobalState *this)

{
  undefined4 uVar1;
  undefined4 uVar2;
  int iVar3;
  undefined4 uVar4;
  undefined4 uVar5;
  int iVar6;
  int iVar7;
  undefined2 local_20;
  undefined2 local_1e [7];
  
  Msg("-- Globals --\n");
  if (0 < *(int *)(this + 0x54)) {
    iVar6 = 0;
    iVar7 = 0;
    do {
      iVar7 = iVar7 + 1;
      iVar3 = *(int *)(this + 0x48) + iVar6;
      uVar1 = *(undefined4 *)(iVar3 + 8);
      local_1e[0] = *(undefined2 *)(iVar3 + 2);
      uVar2 = *(undefined4 *)(DumpGlobals()::estates + *(int *)(iVar3 + 4) * 4);
      uVar4 = CUtlSymbolTable::String((CUtlSymbolTable *)(this + 0xc),local_1e);
      local_20 = *(undefined2 *)(*(int *)(this + 0x48) + iVar6);
      iVar6 = iVar6 + 0xc;
      uVar5 = CUtlSymbolTable::String((CUtlSymbolTable *)(this + 0xc),&local_20);
      Msg("%s: %s (%s) = %d\n",uVar5,uVar4,uVar2,uVar1);
    } while (iVar7 < *(int *)(this + 0x54));
  }
  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)