L L4D2node

CDmxSerializationDictionary::BuildElementList_R

0x00bee900 · 323 bytes · __thiscall

_ZN27CDmxSerializationDictionary18BuildElementList_REP11CDmxElementbb

Decompiled

undefined (4 params)

/* CDmxSerializationDictionary::BuildElementList_R(CDmxElement*, bool, bool) */

void __thiscall
CDmxSerializationDictionary::BuildElementList_R
          (CDmxSerializationDictionary *this,CDmxElement *param_1,bool param_2,bool param_3)

{
  int iVar1;
  int iVar2;
  int *piVar3;
  CDmxElement *pCVar4;
  int iVar5;
  int local_38;
  CDmxElement *local_24;
  undefined1 local_20;
  
  if (param_1 != (CDmxElement *)0x0) {
    local_24 = param_1;
    iVar2 = CUtlRBTree<CDmxSerializationDictionary::DmxElementInfo_t,int,bool(*)(CDmxSerializationDictionary::DmxElementInfo_t_const&,CDmxSerializationDictionary::DmxElementInfo_t_const&),CUtlMemory<UtlRBTreeNode_t<CDmxSerializationDictionary::DmxElementInfo_t,int>,int>>
            ::Find((CUtlRBTree<CDmxSerializationDictionary::DmxElementInfo_t,int,bool(*)(CDmxSerializationDictionary::DmxElementInfo_t_const&,CDmxSerializationDictionary::DmxElementInfo_t_const&),CUtlMemory<UtlRBTreeNode_t<CDmxSerializationDictionary::DmxElementInfo_t,int>,int>>
                    *)this,(DmxElementInfo_t *)&local_24);
    if (iVar2 == -1) {
      local_20 = param_3 || param_2;
      local_24 = param_1;
      CUtlRBTree<CDmxSerializationDictionary::DmxElementInfo_t,int,bool(*)(CDmxSerializationDictionary::DmxElementInfo_t_const&,CDmxSerializationDictionary::DmxElementInfo_t_const&),CUtlMemory<UtlRBTreeNode_t<CDmxSerializationDictionary::DmxElementInfo_t,int>,int>>
      ::Insert((CUtlRBTree<CDmxSerializationDictionary::DmxElementInfo_t,int,bool(*)(CDmxSerializationDictionary::DmxElementInfo_t_const&,CDmxSerializationDictionary::DmxElementInfo_t_const&),CUtlMemory<UtlRBTreeNode_t<CDmxSerializationDictionary::DmxElementInfo_t,int>,int>>
                *)this,(DmxElementInfo_t *)&local_24);
      iVar2 = CDmxElement::AttributeCount(param_1);
      local_38 = 0;
      if (0 < iVar2) {
        do {
          while( true ) {
            piVar3 = (int *)CDmxElement::GetAttribute(param_1,local_38);
            if (*piVar3 == 1) break;
            if (*piVar3 == 0xf) {
              piVar3 = (int *)piVar3[2];
              iVar1 = piVar3[3];
              if ((0 < iVar1) && (pCVar4 = *(CDmxElement **)*piVar3, pCVar4 != (CDmxElement *)0x0))
              {
                iVar5 = 0;
                do {
                  iVar5 = iVar5 + 1;
                  BuildElementList_R(this,pCVar4,param_2,false);
                  if (iVar5 == iVar1) break;
                  pCVar4 = *(CDmxElement **)(*piVar3 + iVar5 * 4);
                } while (pCVar4 != (CDmxElement *)0x0);
              }
            }
LAB_00bee9fc:
            local_38 = local_38 + 1;
            if (local_38 == iVar2) {
              return;
            }
          }
          if (*(CDmxElement **)piVar3[2] == (CDmxElement *)0x0) goto LAB_00bee9fc;
          BuildElementList_R(this,*(CDmxElement **)piVar3[2],param_2,false);
          local_38 = local_38 + 1;
        } while (local_38 != iVar2);
      }
    }
    else {
      *(undefined1 *)(*(int *)(this + 4) + iVar2 * 0x18 + 0x14) = 1;
    }
  }
  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)