L L4D2node

CUtlDict<CActivityRemapCache,int>::Insert

0x003f9ae0 · 178 bytes · __thiscall

_ZN8CUtlDictI19CActivityRemapCacheiE6InsertEPKcRKS0_

Decompiled

undefined (3 params)

/* CUtlDict<CActivityRemapCache, int>::Insert(char const*, CActivityRemapCache const&) */

undefined4 __thiscall
CUtlDict<CActivityRemapCache,int>::Insert
          (CUtlDict<CActivityRemapCache,int> *this,char *param_1,CActivityRemapCache *param_2)

{
  int iVar1;
  undefined4 uVar2;
  int iVar3;
  char *local_34;
  undefined4 local_30;
  undefined4 local_2c;
  undefined4 local_28;
  int local_24;
  undefined4 local_20;
  
  iVar3 = 0;
  local_34 = strdup(param_1);
  local_30 = 0;
  iVar1 = *(int *)(param_2 + 0xc);
  local_2c = 0;
  local_28 = 0;
  local_24 = 0;
  local_20 = 0;
  if (0 < iVar1) {
    do {
                    /* try { // try from 003f9b4e to 003f9b6c has its CatchHandler @ 003f9b98 */
      CUtlVector<CActivityRemap,CUtlMemory<CActivityRemap,int>>::InsertBefore
                ((CUtlVector<CActivityRemap,CUtlMemory<CActivityRemap,int>> *)&local_30,local_24,
                 (CActivityRemap *)(*(int *)param_2 + iVar3 * 0xc));
      iVar3 = iVar3 + 1;
    } while (iVar3 != iVar1);
  }
  uVar2 = CUtlRBTree<CUtlMap<char_const*,CActivityRemapCache,int>::Node_t,int,CUtlMap<char_const*,CActivityRemapCache,int>::CKeyLess,CUtlMemory<UtlRBTreeNode_t<CUtlMap<char_const*,CActivityRemapCache,int>::Node_t,int>,int>>
          ::Insert((CUtlRBTree<CUtlMap<char_const*,CActivityRemapCache,int>::Node_t,int,CUtlMap<char_const*,CActivityRemapCache,int>::CKeyLess,CUtlMemory<UtlRBTreeNode_t<CUtlMap<char_const*,CActivityRemapCache,int>::Node_t,int>,int>>
                    *)this,(Node_t *)&local_34);
  local_24 = 0;
  CUtlMemory<CActivityRemap,int>::Purge((CUtlMemory<CActivityRemap,int> *)&local_30);
  local_20 = local_30;
  CUtlMemory<CActivityRemap,int>::Purge((CUtlMemory<CActivityRemap,int> *)&local_30);
  return uVar2;
}

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)