L L4D2node

CNetworkStringDict::Insert

0x001ac760 · 228 bytes · __thiscall

_ZN18CNetworkStringDict6InsertEPKc

Decompiled

undefined (2 params)

/* CNetworkStringDict::Insert(char const*) */

undefined2 __thiscall CNetworkStringDict::Insert(CNetworkStringDict *this,char *param_1)

{
  CNetworkStringDict CVar1;
  undefined2 uVar2;
  undefined4 uVar3;
  undefined4 local_60;
  CUtlString local_5c [16];
  undefined4 local_4c;
  undefined4 local_48;
  CUtlString local_44 [16];
  undefined4 local_34;
  CNetworkStringTableItem local_30 [32];
  
  local_60 = 0xffffffff;
  CUtlString::CUtlString(local_5c);
  local_4c = 0;
  CVar1 = this[4];
                    /* try { // try from 001ac793 to 001ac7c6 has its CatchHandler @ 001ac845 */
  CUtlString::operator=(local_5c,param_1);
  uVar3 = 0xffffffff;
  if (CVar1 != (CNetworkStringDict)0x0) {
                    /* try { // try from 001ac83b to 001ac83f has its CatchHandler @ 001ac845 */
    uVar3 = CNetworkStringTableDictionaryManager::Find
                      ((CNetworkStringTableDictionaryManager *)&g_StringTableDictionary,param_1);
  }
  local_60 = uVar3;
  CTableItem::ComputeHash((CTableItem *)&local_60);
  local_48 = 0xffffffff;
  CUtlString::CUtlString(local_44);
  local_34 = 0;
                    /* try { // try from 001ac7d4 to 001ac7d8 has its CatchHandler @ 001ac871 */
  CNetworkStringTableItem::CNetworkStringTableItem(local_30);
  local_48 = local_60;
                    /* try { // try from 001ac7e6 to 001ac805 has its CatchHandler @ 001ac857 */
  CUtlString::operator=(local_44,local_5c);
  local_34 = local_4c;
  uVar2 = CUtlRBTree<CUtlMap<CNetworkStringDict::CTableItem,CNetworkStringTableItem,unsigned_short>::Node_t,unsigned_short,CUtlMap<CNetworkStringDict::CTableItem,CNetworkStringTableItem,unsigned_short>::CKeyLess,CUtlMemory<UtlRBTreeNode_t<CUtlMap<CNetworkStringDict::CTableItem,CNetworkStringTableItem,unsigned_short>::Node_t,unsigned_short>,unsigned_short>>
          ::Insert((CUtlRBTree<CUtlMap<CNetworkStringDict::CTableItem,CNetworkStringTableItem,unsigned_short>::Node_t,unsigned_short,CUtlMap<CNetworkStringDict::CTableItem,CNetworkStringTableItem,unsigned_short>::CKeyLess,CUtlMemory<UtlRBTreeNode_t<CUtlMap<CNetworkStringDict::CTableItem,CNetworkStringTableItem,unsigned_short>::Node_t,unsigned_short>,unsigned_short>>
                    *)(this + 8),(Node_t *)&local_48);
  CNetworkStringTableItem::~CNetworkStringTableItem(local_30);
  CUtlMemory<unsigned_char,int>::Purge((CUtlMemory<unsigned_char,int> *)local_44);
  CUtlMemory<unsigned_char,int>::Purge((CUtlMemory<unsigned_char,int> *)local_5c);
  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)