L L4D2node

CUtlRBTree<VisibilityCacheEntry_t,unsigned_short,CVisibilityCacheEntryLess,CUtlMemory<UtlRBTreeNode_t<VisibilityCacheEntry_t,unsigned_short>,unsigned_short>>::NextInorder

0x005f9230 · 1176 bytes · __thiscall

_ZNK10CUtlRBTreeI22VisibilityCacheEntry_tt25CVisibilityCacheEntryLess10CUtlMemoryI15UtlRBTreeNode_tIS0_tEtEE11NextInorderEt

Decompiled

undefined (2 params)

/* CUtlRBTree<VisibilityCacheEntry_t, unsigned short, CVisibilityCacheEntryLess,
   CUtlMemory<UtlRBTreeNode_t<VisibilityCacheEntry_t, unsigned short>, unsigned short>
   >::NextInorder(unsigned short) const */

ushort __thiscall
CUtlRBTree<VisibilityCacheEntry_t,unsigned_short,CVisibilityCacheEntryLess,CUtlMemory<UtlRBTreeNode_t<VisibilityCacheEntry_t,unsigned_short>,unsigned_short>>
::NextInorder(CUtlRBTree<VisibilityCacheEntry_t,unsigned_short,CVisibilityCacheEntryLess,CUtlMemory<UtlRBTreeNode_t<VisibilityCacheEntry_t,unsigned_short>,unsigned_short>>
              *this,ushort param_1)

{
  ushort uVar1;
  short sVar2;
  int iVar3;
  ushort *puVar4;
  undefined2 *puVar5;
  short sVar6;
  uint uVar7;
  short sVar8;
  uint uVar9;
  
  uVar1 = param_1;
  _param_1 = (uint)param_1;
  if ((Links(unsigned_short)::s_Sentinel == '\0') &&
     (iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar3 != 0)) {
    Links(unsigned_short)::s_Sentinel = -1;
    DAT_00f244ba = -1;
    DAT_00f244bc = 0xffff;
    __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
  }
  sVar8 = DAT_00f244ba;
  if (uVar1 != 0xffff) {
    sVar8 = *(short *)(*(int *)(this + 4) + (uint)uVar1 * 0x18 + 2);
  }
  if (sVar8 == -1) {
    if ((Links(unsigned_short)::s_Sentinel == '\0') &&
       (iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar3 != 0)) {
      Links(unsigned_short)::s_Sentinel = -1;
      DAT_00f244ba = -1;
      DAT_00f244bc = 0xffff;
      __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
    }
    if (uVar1 == 0xffff) {
      puVar5 = &Links(unsigned_short)::s_Sentinel;
    }
    else {
      puVar5 = (undefined2 *)(*(int *)(this + 4) + (uint)uVar1 * 0x18);
    }
    uVar1 = puVar5[2];
    do {
      uVar9 = (uint)uVar1;
      sVar8 = (short)_param_1;
      if (Links(unsigned_short)::s_Sentinel == '\0') {
        iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
        if (iVar3 != 0) {
          DAT_00f244ba = -1;
          DAT_00f244bc = 0xffff;
          Links(unsigned_short)::s_Sentinel = -1;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          goto LAB_005f9428;
        }
        if (sVar8 != -1) goto LAB_005f9432;
LAB_005f94bf:
        uVar7 = (uint)DAT_00f244bc;
        if (Links(unsigned_short)::s_Sentinel != '\0') goto LAB_005f944a;
LAB_005f94d0:
        iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
        if (iVar3 == 0) goto LAB_005f944a;
        DAT_00f244ba = -1;
        Links(unsigned_short)::s_Sentinel = -1;
        DAT_00f244bc = 0xffff;
        __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        sVar6 = (short)uVar7;
      }
      else {
LAB_005f9428:
        if (sVar8 == -1) goto LAB_005f94bf;
LAB_005f9432:
        uVar7 = (uint)*(ushort *)(*(int *)(this + 4) + _param_1 * 0x18 + 4);
        if (Links(unsigned_short)::s_Sentinel == '\0') goto LAB_005f94d0;
LAB_005f944a:
        sVar6 = (short)uVar7;
      }
      sVar2 = DAT_00f244ba;
      if (sVar6 != -1) {
        sVar2 = *(short *)(*(int *)(this + 4) + uVar7 * 0x18 + 2);
      }
      if (sVar8 != sVar2) {
        return uVar1;
      }
      if (uVar1 == 0xffff) {
        return 0xffff;
      }
      if ((Links(unsigned_short)::s_Sentinel == '\0') &&
         (iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar3 != 0)) {
        Links(unsigned_short)::s_Sentinel = -1;
        DAT_00f244ba = -1;
        DAT_00f244bc = 0xffff;
        __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
      }
      uVar1 = *(ushort *)(*(int *)(this + 4) + 4 + uVar9 * 0x18);
      _param_1 = uVar9;
    } while( true );
  }
  if ((Links(unsigned_short)::s_Sentinel == '\0') &&
     (iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar3 != 0)) {
    Links(unsigned_short)::s_Sentinel = -1;
    DAT_00f244ba = -1;
    DAT_00f244bc = 0xffff;
    __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
  }
  if (uVar1 == 0xffff) {
    puVar5 = &Links(unsigned_short)::s_Sentinel;
  }
  else {
    puVar5 = (undefined2 *)(*(int *)(this + 4) + (uint)uVar1 * 0x18);
  }
  uVar1 = puVar5[1];
  do {
    if ((Links(unsigned_short)::s_Sentinel == '\0') &&
       (iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar3 != 0)) {
      DAT_00f244ba = -1;
      Links(unsigned_short)::s_Sentinel = -1;
      DAT_00f244bc = 0xffff;
      __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
    }
    sVar8 = Links(unsigned_short)::s_Sentinel;
    if (uVar1 != 0xffff) {
      sVar8 = *(short *)(*(int *)(this + 4) + (uint)uVar1 * 0x18);
    }
    if (sVar8 == -1) {
      return uVar1;
    }
    if (Links(unsigned_short)::s_Sentinel == '\0') {
      iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
      if (iVar3 != 0) {
        Links(unsigned_short)::s_Sentinel = -1;
        DAT_00f244ba = -1;
        DAT_00f244bc = 0xffff;
        __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
      }
      if (uVar1 != 0xffff) goto LAB_005f92d9;
LAB_005f9381:
      puVar4 = (ushort *)&Links(unsigned_short)::s_Sentinel;
    }
    else {
      if (uVar1 == 0xffff) goto LAB_005f9381;
LAB_005f92d9:
      puVar4 = (ushort *)(*(int *)(this + 4) + (uint)uVar1 * 0x18);
    }
    uVar1 = *puVar4;
  } while( true );
}

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)