L L4D2node

CDmxSerializerKeyValues2::Unserialize

0x00bee190 · 232 bytes · __thiscall

_ZN24CDmxSerializerKeyValues211UnserializeEPKcR10CUtlBufferPP11CDmxElement

Decompiled

undefined (4 params)

/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
/* CDmxSerializerKeyValues2::Unserialize(char const*, CUtlBuffer&, CDmxElement**) */

undefined4 __thiscall
CDmxSerializerKeyValues2::Unserialize
          (CDmxSerializerKeyValues2 *this,char *param_1,CUtlBuffer *param_2,CDmxElement **param_3)

{
  undefined4 uVar1;
  CDmxElement *pCVar2;
  int local_20 [4];
  
  *param_3 = (CDmxElement *)0x0;
  _DAT_0105b76c = 0;
  _DAT_0105b764 = 1;
  _DAT_0105b760 = param_1;
  *(undefined4 *)(this + 0x3c) = 0xffffffff;
  CDmxElementDictionary::Clear((CDmxElementDictionary *)this);
  while (param_2[0x14] == (CUtlBuffer)0x0) {
    while( true ) {
      uVar1 = UnserializeElement(this,param_2,local_20);
      if (((char)uVar1 == '\0') || (local_20[0] == -1)) goto LAB_00bee216;
      if (*(int *)(this + 0x3c) != -1) break;
      *(int *)(this + 0x3c) = local_20[0];
      if (param_2[0x14] != (CUtlBuffer)0x0) goto LAB_00bee211;
    }
  }
LAB_00bee211:
  uVar1 = 1;
LAB_00bee216:
  pCVar2 = (CDmxElement *)0x0;
  CDmxElementDictionary::HookUpElementArrayAttributes((CDmxElementDictionary *)this);
  CDmxElementDictionary::HookUpElementAttributes((CDmxElementDictionary *)this);
  if (*(int *)(this + 0x3c) != -1) {
    pCVar2 = *(CDmxElement **)(*(int *)this + *(int *)(this + 0x3c) * 0x14);
  }
  *param_3 = pCVar2;
  CDmxElementDictionary::Clear((CDmxElementDictionary *)this);
  if ((char)uVar1 == '\0') {
    CleanupDMX(*param_3);
    *param_3 = (CDmxElement *)0x0;
  }
  return uVar1;
}

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)