L L4D2node

CPureServerWhitelist::UpdateCommandStats

0x001d70b0 · 129 bytes · __thiscall

_ZN20CPureServerWhitelist18UpdateCommandStatsER8CUtlDictIPNS_8CCommandEiEPiS5_

Decompiled

undefined (4 params)

/* CPureServerWhitelist::UpdateCommandStats(CUtlDict<CPureServerWhitelist::CCommand*, int>&, int*,
   int*) */

void __thiscall
CPureServerWhitelist::UpdateCommandStats
          (CPureServerWhitelist *this,CUtlDict *param_1,int *param_2,int *param_3)

{
  int iVar1;
  int iVar2;
  uint uVar3;
  int iVar4;
  
  for (iVar1 = CUtlRBTree<CUtlMap<char_const*,CPureServerWhitelist::CCommand*,int>::Node_t,int,CUtlMap<char_const*,CPureServerWhitelist::CCommand*,int>::CKeyLess,CUtlMemory<UtlRBTreeNode_t<CUtlMap<char_const*,CPureServerWhitelist::CCommand*,int>::Node_t,int>,int>>
               ::FirstInorder((CUtlRBTree<CUtlMap<char_const*,CPureServerWhitelist::CCommand*,int>::Node_t,int,CUtlMap<char_const*,CPureServerWhitelist::CCommand*,int>::CKeyLess,CUtlMemory<UtlRBTreeNode_t<CUtlMap<char_const*,CPureServerWhitelist::CCommand*,int>::Node_t,int>,int>>
                               *)param_1); iVar1 != -1;
      iVar1 = CUtlRBTree<CUtlMap<char_const*,CPureServerWhitelist::CCommand*,int>::Node_t,int,CUtlMap<char_const*,CPureServerWhitelist::CCommand*,int>::CKeyLess,CUtlMemory<UtlRBTreeNode_t<CUtlMap<char_const*,CPureServerWhitelist::CCommand*,int>::Node_t,int>,int>>
              ::NextInorder((CUtlRBTree<CUtlMap<char_const*,CPureServerWhitelist::CCommand*,int>::Node_t,int,CUtlMap<char_const*,CPureServerWhitelist::CCommand*,int>::CKeyLess,CUtlMemory<UtlRBTreeNode_t<CUtlMap<char_const*,CPureServerWhitelist::CCommand*,int>::Node_t,int>,int>>
                             *)param_1,iVar1)) {
    uVar3 = (uint)*(ushort *)(*(int *)(*(int *)(param_1 + 4) + 0x14 + iVar1 * 0x18) + 2);
    if ((int)uVar3 <= *param_2) {
      uVar3 = *param_2;
    }
    *param_2 = uVar3;
    iVar2 = _V_strlen(*(char **)(*(int *)(param_1 + 4) + 0x10 + iVar1 * 0x18));
    iVar4 = *param_3;
    if (*param_3 <= iVar2) {
      iVar4 = iVar2;
    }
    *param_3 = iVar4;
  }
  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)