L L4D2node

CUtlRBTree<CUtlMap<IPhysicsObject*,CPhysCollide_const*,unsigned_short>::Node_t,unsigned_short,CUtlMap<IPhysicsObject*,CPhysCollide_const*,unsigned_short>::CKeyLess,CUtlMemory<UtlRBTreeNode_t<CUtlMap<IPhysicsObject*,CPhysCollide_const*,unsigned_short>::Node_t,unsigned_short>,unsigned_short>>::RemoveRebalance

0x0048f350 · 5563 bytes · __thiscall

_ZN10CUtlRBTreeIN7CUtlMapIP14IPhysicsObjectPK12CPhysCollidetE6Node_tEtNS6_8CKeyLessE10CUtlMemoryI15UtlRBTreeNode_tIS7_tEtEE15RemoveRebalanceEt

Decompiled

undefined (2 params)

/* CUtlRBTree<CUtlMap<IPhysicsObject*, CPhysCollide const*, unsigned short>::Node_t, unsigned short,
   CUtlMap<IPhysicsObject*, CPhysCollide const*, unsigned short>::CKeyLess,
   CUtlMemory<UtlRBTreeNode_t<CUtlMap<IPhysicsObject*, CPhysCollide const*, unsigned short>::Node_t,
   unsigned short>, unsigned short> >::RemoveRebalance(unsigned short) */

void __thiscall
CUtlRBTree<CUtlMap<IPhysicsObject*,CPhysCollide_const*,unsigned_short>::Node_t,unsigned_short,CUtlMap<IPhysicsObject*,CPhysCollide_const*,unsigned_short>::CKeyLess,CUtlMemory<UtlRBTreeNode_t<CUtlMap<IPhysicsObject*,CPhysCollide_const*,unsigned_short>::Node_t,unsigned_short>,unsigned_short>>
::RemoveRebalance(CUtlRBTree<CUtlMap<IPhysicsObject*,CPhysCollide_const*,unsigned_short>::Node_t,unsigned_short,CUtlMap<IPhysicsObject*,CPhysCollide_const*,unsigned_short>::CKeyLess,CUtlMemory<UtlRBTreeNode_t<CUtlMap<IPhysicsObject*,CPhysCollide_const*,unsigned_short>::Node_t,unsigned_short>,unsigned_short>>
                  *this,ushort param_1)

{
  short sVar1;
  uint uVar2;
  int iVar3;
  undefined2 *puVar4;
  ushort uVar5;
  ushort uVar6;
  ushort *puVar7;
  uint uVar8;
  ushort uVar9;
  ushort uVar11;
  bool bVar12;
  int local_28;
  int local_24;
  uint uVar10;
  
  uVar2 = (uint)*(ushort *)(this + 0x10);
  uVar10 = (uint)param_1;
  while (uVar9 = (ushort)uVar10, uVar9 != (ushort)uVar2) {
    if ((Links(unsigned_short)::s_Sentinel == '\0') &&
       (iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar3 != 0)) {
      Links(unsigned_short)::s_Sentinel = 0xffff;
      DAT_00f165d8 = 0xffff;
      DAT_00f165da = 0xffff;
      __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
    }
    sVar1 = DAT_00f165dc;
    if (uVar9 != 0xffff) {
      sVar1 = *(short *)(uVar10 * 0x10 + *(int *)(this + 4) + 6);
    }
    if (sVar1 != 1) break;
    if (Links(unsigned_short)::s_Sentinel == '\0') {
      iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
      if (iVar3 != 0) {
        DAT_00f165d8 = 0xffff;
        Links(unsigned_short)::s_Sentinel = 0xffff;
        DAT_00f165da = 0xffff;
        __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
      }
      if (uVar9 != 0xffff) goto LAB_0048f421;
LAB_0048f5e5:
      uVar2 = (uint)DAT_00f165da;
      uVar11 = DAT_00f165da;
      if (Links(unsigned_short)::s_Sentinel != '\0') goto LAB_0048f439;
LAB_0048f600:
      iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
      if (iVar3 != 0) {
        Links(unsigned_short)::s_Sentinel = 0xffff;
        DAT_00f165da = 0xffff;
        DAT_00f165d8 = 0xffff;
        __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        goto LAB_0048f439;
      }
      if (uVar11 != 0xffff) goto LAB_0048f443;
LAB_0048f62b:
      if (uVar9 != Links(unsigned_short)::s_Sentinel) goto LAB_0048f454;
LAB_0048f640:
      if (Links(unsigned_short)::s_Sentinel == '\0') {
        iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
        if (iVar3 != 0) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f165d8 = 0xffff;
          DAT_00f165da = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          goto LAB_0048f648;
        }
        if (uVar11 != 0xffff) goto LAB_0048f652;
LAB_0048ff4b:
        puVar4 = &Links(unsigned_short)::s_Sentinel;
      }
      else {
LAB_0048f648:
        if (uVar11 == 0xffff) goto LAB_0048ff4b;
LAB_0048f652:
        puVar4 = (undefined2 *)(uVar2 * 0x10 + *(int *)(this + 4));
      }
      uVar6 = puVar4[1];
      uVar8 = (uint)uVar6;
      if ((Links(unsigned_short)::s_Sentinel == '\0') &&
         (iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar3 != 0)) {
        DAT_00f165d8 = 0xffff;
        Links(unsigned_short)::s_Sentinel = 0xffff;
        DAT_00f165da = 0xffff;
        __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        if (uVar6 != 0xffff) goto LAB_0048f670;
LAB_0048ff10:
        puVar4 = &Links(unsigned_short)::s_Sentinel;
      }
      else {
        if (uVar6 == 0xffff) goto LAB_0048ff10;
LAB_0048f670:
        puVar4 = (undefined2 *)(uVar8 * 0x10 + *(int *)(this + 4));
      }
      if (puVar4[3] == 0) {
        *(undefined2 *)(uVar8 * 0x10 + *(int *)(this + 4) + 6) = 1;
        *(undefined2 *)(uVar2 * 0x10 + *(int *)(this + 4) + 6) = 0;
        RotateLeft(this,(ushort)uVar2);
        if (Links(unsigned_short)::s_Sentinel == '\0') {
          iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
          if (iVar3 != 0) {
            Links(unsigned_short)::s_Sentinel = 0xffff;
            DAT_00f165d8 = 0xffff;
            DAT_00f165da = 0xffff;
            __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          }
          if (uVar9 != 0xffff) goto LAB_0048fe78;
LAB_00490388:
          puVar4 = &Links(unsigned_short)::s_Sentinel;
        }
        else {
          if (uVar9 == 0xffff) goto LAB_00490388;
LAB_0048fe78:
          puVar4 = (undefined2 *)(uVar10 * 0x10 + *(int *)(this + 4));
        }
        uVar11 = puVar4[2];
        if (Links(unsigned_short)::s_Sentinel == '\0') {
          iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
          if (iVar3 != 0) {
            Links(unsigned_short)::s_Sentinel = 0xffff;
            DAT_00f165d8 = 0xffff;
            DAT_00f165da = 0xffff;
            __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          }
          if (uVar11 != 0xffff) goto LAB_0048fe99;
LAB_00490350:
          puVar4 = &Links(unsigned_short)::s_Sentinel;
        }
        else {
          if (uVar11 == 0xffff) goto LAB_00490350;
LAB_0048fe99:
          puVar4 = (undefined2 *)((uint)uVar11 * 0x10 + *(int *)(this + 4));
        }
        uVar8 = (uint)(ushort)puVar4[1];
      }
      uVar6 = (ushort)uVar8;
      if (Links(unsigned_short)::s_Sentinel == '\0') {
        iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
        if (iVar3 != 0) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f165d8 = 0xffff;
          DAT_00f165da = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          goto LAB_0048f698;
        }
        if (uVar6 != 0xffff) goto LAB_0048f6a2;
LAB_0048fe26:
        puVar7 = &Links(unsigned_short)::s_Sentinel;
      }
      else {
LAB_0048f698:
        if (uVar6 == 0xffff) goto LAB_0048fe26;
LAB_0048f6a2:
        puVar7 = (ushort *)(uVar8 * 0x10 + *(int *)(this + 4));
      }
      uVar5 = *puVar7;
      if (Links(unsigned_short)::s_Sentinel == '\0') {
        iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
        if (iVar3 != 0) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f165d8 = 0xffff;
          DAT_00f165da = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          goto LAB_0048f6b8;
        }
        if (uVar5 != 0xffff) goto LAB_0048f6c2;
LAB_0048fbfc:
        if (DAT_00f165dc != 1) goto joined_r0x0048fc63;
LAB_0048fc0c:
        if ((Links(unsigned_short)::s_Sentinel == '\0') &&
           (iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar3 != 0)) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f165d8 = 0xffff;
          DAT_00f165da = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        }
        if (uVar6 == 0xffff) {
          puVar4 = &Links(unsigned_short)::s_Sentinel;
        }
        else {
          puVar4 = (undefined2 *)(uVar8 * 0x10 + *(int *)(this + 4));
        }
        uVar5 = puVar4[1];
        if ((Links(unsigned_short)::s_Sentinel == '\0') &&
           (iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar3 != 0)) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f165d8 = 0xffff;
          DAT_00f165da = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        }
        if (uVar5 == 0xffff) {
          puVar4 = &Links(unsigned_short)::s_Sentinel;
        }
        else {
          puVar4 = (undefined2 *)((uint)uVar5 * 0x10 + *(int *)(this + 4));
        }
        if (puVar4[3] != 1) goto joined_r0x0048fc63;
LAB_00490120:
        if ((short)uVar8 == -1) {
          uVar2 = (uint)*(ushort *)(this + 0x10);
          uVar10 = (uint)uVar11;
        }
        else {
          *(undefined2 *)(uVar8 * 0x10 + *(int *)(this + 4) + 6) = 0;
          uVar2 = (uint)*(ushort *)(this + 0x10);
          uVar10 = (uint)uVar11;
        }
      }
      else {
LAB_0048f6b8:
        if (uVar5 == 0xffff) goto LAB_0048fbfc;
LAB_0048f6c2:
        if (*(short *)((uint)uVar5 * 0x10 + *(int *)(this + 4) + 6) == 1) goto LAB_0048fc0c;
joined_r0x0048fc63:
        if (Links(unsigned_short)::s_Sentinel == '\0') {
          iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
          if (iVar3 != 0) {
            Links(unsigned_short)::s_Sentinel = 0xffff;
            DAT_00f165d8 = 0xffff;
            DAT_00f165da = 0xffff;
            __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
            goto LAB_0048f6e0;
          }
          if (uVar6 != 0xffff) goto LAB_0048f6ea;
LAB_0048fc9e:
          local_24 = 0xffff0;
          uVar5 = DAT_00f165d8;
          if (Links(unsigned_short)::s_Sentinel != '\0') goto LAB_0048f708;
LAB_0048fcb8:
          iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
          if (iVar3 != 0) {
            Links(unsigned_short)::s_Sentinel = 0xffff;
            DAT_00f165d8 = 0xffff;
            DAT_00f165da = 0xffff;
            __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
            goto LAB_0048f708;
          }
          if (uVar5 != 0xffff) goto LAB_0048f712;
LAB_0048fcec:
          if (DAT_00f165dc != 1) goto LAB_0048f726;
LAB_0048fd00:
          if ((Links(unsigned_short)::s_Sentinel == '\0') &&
             (iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar3 != 0)) {
            DAT_00f165d8 = 0xffff;
            Links(unsigned_short)::s_Sentinel = 0xffff;
            DAT_00f165da = 0xffff;
            __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          }
          puVar7 = &Links(unsigned_short)::s_Sentinel;
          if (uVar6 != 0xffff) {
            puVar7 = (ushort *)(local_24 + *(int *)(this + 4));
          }
          *(undefined2 *)(*(int *)(this + 4) + 6 + (uint)*puVar7 * 0x10) = 1;
          *(undefined2 *)(*(int *)(this + 4) + 6 + local_24) = 0;
          RotateRight(this,uVar6);
          if ((Links(unsigned_short)::s_Sentinel == '\0') &&
             (iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar3 != 0)) {
            Links(unsigned_short)::s_Sentinel = 0xffff;
            DAT_00f165d8 = 0xffff;
            DAT_00f165da = 0xffff;
            __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          }
          if (uVar9 == 0xffff) {
            puVar4 = &Links(unsigned_short)::s_Sentinel;
          }
          else {
            puVar4 = (undefined2 *)(uVar10 * 0x10 + *(int *)(this + 4));
          }
          uVar11 = puVar4[2];
          if ((Links(unsigned_short)::s_Sentinel == '\0') &&
             (iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar3 != 0)) {
            Links(unsigned_short)::s_Sentinel = 0xffff;
            DAT_00f165d8 = 0xffff;
            DAT_00f165da = 0xffff;
            __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          }
          if (uVar11 == 0xffff) {
            local_28 = 0xffff0;
            puVar4 = &Links(unsigned_short)::s_Sentinel;
            uVar9 = 0xffff;
          }
          else {
            local_28 = (uint)uVar11 * 0x10;
            puVar4 = (undefined2 *)(*(int *)(this + 4) + local_28);
            uVar9 = uVar11;
          }
          uVar6 = puVar4[1];
          local_24 = (uint)uVar6 << 4;
          if (Links(unsigned_short)::s_Sentinel == '\0') goto LAB_0048fdb0;
LAB_0048f73b:
          iVar3 = *(int *)(this + 4);
          if (uVar11 != 0xffff) goto LAB_0048f748;
LAB_0048fde7:
          puVar4 = &Links(unsigned_short)::s_Sentinel;
        }
        else {
LAB_0048f6e0:
          if (uVar6 == 0xffff) goto LAB_0048fc9e;
LAB_0048f6ea:
          local_24 = uVar8 * 0x10;
          uVar5 = *(ushort *)(local_24 + *(int *)(this + 4) + 2);
          if (Links(unsigned_short)::s_Sentinel == '\0') goto LAB_0048fcb8;
LAB_0048f708:
          if (uVar5 == 0xffff) goto LAB_0048fcec;
LAB_0048f712:
          if (*(short *)((uint)uVar5 * 0x10 + *(int *)(this + 4) + 6) == 1) goto LAB_0048fd00;
LAB_0048f726:
          local_28 = (uint)uVar11 << 4;
          uVar9 = uVar11;
          if (Links(unsigned_short)::s_Sentinel != '\0') goto LAB_0048f73b;
LAB_0048fdb0:
          iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
          if (iVar3 != 0) {
            Links(unsigned_short)::s_Sentinel = 0xffff;
            DAT_00f165d8 = 0xffff;
            DAT_00f165da = 0xffff;
            __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
            goto LAB_0048f73b;
          }
          iVar3 = *(int *)(this + 4);
          if (uVar11 == 0xffff) goto LAB_0048fde7;
LAB_0048f748:
          puVar4 = (undefined2 *)(iVar3 + local_28);
        }
        bVar12 = Links(unsigned_short)::s_Sentinel == '\0';
        *(undefined2 *)(iVar3 + 6 + local_24) = puVar4[3];
        *(undefined2 *)(*(int *)(this + 4) + 6 + local_28) = 1;
        if ((bVar12) &&
           (iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar3 != 0)) {
          DAT_00f165d8 = 0xffff;
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f165da = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        }
        if (uVar6 == 0xffff) {
          puVar4 = &Links(unsigned_short)::s_Sentinel;
        }
        else {
          puVar4 = (undefined2 *)(local_24 + *(int *)(this + 4));
        }
        *(undefined2 *)(*(int *)(this + 4) + 6 + (uint)(ushort)puVar4[1] * 0x10) = 1;
        RotateLeft(this,uVar9);
        uVar2 = (uint)*(ushort *)(this + 0x10);
        uVar10 = uVar2;
      }
    }
    else {
      if (uVar9 == 0xffff) goto LAB_0048f5e5;
LAB_0048f421:
      uVar11 = *(ushort *)(uVar10 * 0x10 + *(int *)(this + 4) + 4);
      uVar2 = (uint)uVar11;
      if (Links(unsigned_short)::s_Sentinel == '\0') goto LAB_0048f600;
LAB_0048f439:
      if (uVar11 == 0xffff) goto LAB_0048f62b;
LAB_0048f443:
      if (uVar9 == *(ushort *)(uVar2 * 0x10 + *(int *)(this + 4))) goto LAB_0048f640;
LAB_0048f454:
      if (Links(unsigned_short)::s_Sentinel == '\0') {
        iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
        if (iVar3 != 0) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f165d8 = 0xffff;
          DAT_00f165da = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          goto LAB_0048f45c;
        }
        if (uVar11 != 0xffff) goto LAB_0048f466;
LAB_0048fb3b:
        puVar7 = &Links(unsigned_short)::s_Sentinel;
      }
      else {
LAB_0048f45c:
        if (uVar11 == 0xffff) goto LAB_0048fb3b;
LAB_0048f466:
        puVar7 = (ushort *)(uVar2 * 0x10 + *(int *)(this + 4));
      }
      uVar6 = *puVar7;
      uVar8 = (uint)uVar6;
      if ((Links(unsigned_short)::s_Sentinel == '\0') &&
         (iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar3 != 0)) {
        DAT_00f165d8 = 0xffff;
        Links(unsigned_short)::s_Sentinel = 0xffff;
        DAT_00f165da = 0xffff;
        __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        if (uVar6 != 0xffff) goto LAB_0048f483;
LAB_0048fa40:
        if (DAT_00f165dc != 0) goto LAB_0048f497;
LAB_0048fa50:
        *(undefined2 *)(uVar8 * 0x10 + *(int *)(this + 4) + 6) = 1;
        *(undefined2 *)(uVar2 * 0x10 + *(int *)(this + 4) + 6) = 0;
        RotateRight(this,(ushort)uVar2);
        if (Links(unsigned_short)::s_Sentinel == '\0') {
          iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
          if (iVar3 != 0) {
            DAT_00f165da = 0xffff;
            Links(unsigned_short)::s_Sentinel = 0xffff;
            DAT_00f165d8 = 0xffff;
            __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          }
          if (uVar9 != 0xffff) goto LAB_0048fa98;
LAB_0048ffb8:
          puVar4 = &Links(unsigned_short)::s_Sentinel;
        }
        else {
          if (uVar9 == 0xffff) goto LAB_0048ffb8;
LAB_0048fa98:
          puVar4 = (undefined2 *)(uVar10 * 0x10 + *(int *)(this + 4));
        }
        uVar11 = puVar4[2];
        if (Links(unsigned_short)::s_Sentinel == '\0') {
          iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
          if (iVar3 != 0) {
            Links(unsigned_short)::s_Sentinel = 0xffff;
            DAT_00f165d8 = 0xffff;
            DAT_00f165da = 0xffff;
            __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          }
          if (uVar11 != 0xffff) goto LAB_0048fab9;
LAB_0048ff80:
          puVar7 = &Links(unsigned_short)::s_Sentinel;
        }
        else {
          if (uVar11 == 0xffff) goto LAB_0048ff80;
LAB_0048fab9:
          puVar7 = (ushort *)((uint)uVar11 * 0x10 + *(int *)(this + 4));
        }
        uVar8 = (uint)*puVar7;
        if (Links(unsigned_short)::s_Sentinel != '\0') goto LAB_0048f4ab;
LAB_0048facf:
        iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
        if (iVar3 != 0) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f165d8 = 0xffff;
          DAT_00f165da = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          goto LAB_0048f4ab;
        }
        if ((short)uVar8 != -1) goto LAB_0048f4b5;
LAB_0048fafd:
        puVar4 = &Links(unsigned_short)::s_Sentinel;
      }
      else {
        if (uVar6 == 0xffff) goto LAB_0048fa40;
LAB_0048f483:
        if (*(short *)(uVar8 * 0x10 + *(int *)(this + 4) + 6) == 0) goto LAB_0048fa50;
LAB_0048f497:
        if (Links(unsigned_short)::s_Sentinel == '\0') goto LAB_0048facf;
LAB_0048f4ab:
        if ((short)uVar8 == -1) goto LAB_0048fafd;
LAB_0048f4b5:
        puVar4 = (undefined2 *)(uVar8 * 0x10 + *(int *)(this + 4));
      }
      uVar6 = puVar4[1];
      uVar5 = (ushort)uVar8;
      if (Links(unsigned_short)::s_Sentinel == '\0') {
        iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
        if (iVar3 != 0) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f165d8 = 0xffff;
          DAT_00f165da = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          goto LAB_0048f4cc;
        }
        if (uVar6 != 0xffff) goto LAB_0048f4d6;
LAB_0048f7e4:
        if (DAT_00f165dc != 1) goto LAB_0048f4ea;
LAB_0048f7f8:
        if ((Links(unsigned_short)::s_Sentinel == '\0') &&
           (iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar3 != 0)) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f165d8 = 0xffff;
          DAT_00f165da = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        }
        uVar6 = Links(unsigned_short)::s_Sentinel;
        if (uVar5 != 0xffff) {
          uVar6 = *(ushort *)(uVar8 * 0x10 + *(int *)(this + 4));
        }
        if ((Links(unsigned_short)::s_Sentinel == '\0') &&
           (iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar3 != 0)) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f165d8 = 0xffff;
          DAT_00f165da = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        }
        if (uVar6 == 0xffff) {
          puVar4 = &Links(unsigned_short)::s_Sentinel;
        }
        else {
          puVar4 = (undefined2 *)((uint)uVar6 * 0x10 + *(int *)(this + 4));
        }
        if (puVar4[3] == 1) goto LAB_00490120;
        if (Links(unsigned_short)::s_Sentinel == '\0') goto LAB_0048f858;
LAB_0048f4f4:
        if (uVar5 != 0xffff) goto LAB_0048f4fe;
LAB_0048f886:
        local_24 = 0xffff0;
        uVar6 = Links(unsigned_short)::s_Sentinel;
        if (Links(unsigned_short)::s_Sentinel == '\0') goto LAB_0048f8a0;
LAB_0048f51b:
        if (uVar6 != 0xffff) goto LAB_0048f525;
LAB_0048f8d4:
        if (DAT_00f165dc != 1) goto LAB_0048f539;
LAB_0048f8e8:
        if ((Links(unsigned_short)::s_Sentinel == '\0') &&
           (iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar3 != 0)) {
          DAT_00f165d8 = 0xffff;
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f165da = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        }
        puVar4 = &Links(unsigned_short)::s_Sentinel;
        if (uVar5 != 0xffff) {
          puVar4 = (undefined2 *)(local_24 + *(int *)(this + 4));
        }
        *(undefined2 *)(*(int *)(this + 4) + 6 + (uint)(ushort)puVar4[1] * 0x10) = 1;
        *(undefined2 *)(*(int *)(this + 4) + 6 + local_24) = 0;
        RotateLeft(this,uVar5);
        if ((Links(unsigned_short)::s_Sentinel == '\0') &&
           (iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar3 != 0)) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f165d8 = 0xffff;
          DAT_00f165da = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        }
        if (uVar9 == 0xffff) {
          puVar4 = &Links(unsigned_short)::s_Sentinel;
        }
        else {
          puVar4 = (undefined2 *)(uVar10 * 0x10 + *(int *)(this + 4));
        }
        uVar11 = puVar4[2];
        if ((Links(unsigned_short)::s_Sentinel == '\0') &&
           (iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar3 != 0)) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f165d8 = 0xffff;
          DAT_00f165da = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        }
        if (uVar11 == 0xffff) {
          local_28 = 0xffff0;
          puVar7 = &Links(unsigned_short)::s_Sentinel;
          uVar9 = 0xffff;
        }
        else {
          local_28 = (uint)uVar11 * 0x10;
          puVar7 = (ushort *)(*(int *)(this + 4) + local_28);
          uVar9 = uVar11;
        }
        uVar5 = *puVar7;
        local_24 = (uint)uVar5 << 4;
        if (Links(unsigned_short)::s_Sentinel != '\0') goto LAB_0048f54e;
LAB_0048f998:
        iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
        if (iVar3 != 0) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f165d8 = 0xffff;
          DAT_00f165da = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          goto LAB_0048f54e;
        }
        iVar3 = *(int *)(this + 4);
        if (uVar11 != 0xffff) goto LAB_0048f55b;
LAB_0048f9cf:
        puVar4 = &Links(unsigned_short)::s_Sentinel;
      }
      else {
LAB_0048f4cc:
        if (uVar6 == 0xffff) goto LAB_0048f7e4;
LAB_0048f4d6:
        if (*(short *)((uint)uVar6 * 0x10 + *(int *)(this + 4) + 6) == 1) goto LAB_0048f7f8;
LAB_0048f4ea:
        if (Links(unsigned_short)::s_Sentinel != '\0') goto LAB_0048f4f4;
LAB_0048f858:
        iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
        if (iVar3 != 0) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f165d8 = 0xffff;
          DAT_00f165da = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          goto LAB_0048f4f4;
        }
        if (uVar5 == 0xffff) goto LAB_0048f886;
LAB_0048f4fe:
        local_24 = uVar8 * 0x10;
        uVar6 = *(ushort *)(local_24 + *(int *)(this + 4));
        if (Links(unsigned_short)::s_Sentinel != '\0') goto LAB_0048f51b;
LAB_0048f8a0:
        iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
        if (iVar3 != 0) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f165d8 = 0xffff;
          DAT_00f165da = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          goto LAB_0048f51b;
        }
        if (uVar6 == 0xffff) goto LAB_0048f8d4;
LAB_0048f525:
        if (*(short *)((uint)uVar6 * 0x10 + *(int *)(this + 4) + 6) == 1) goto LAB_0048f8e8;
LAB_0048f539:
        local_28 = (uint)uVar11 << 4;
        uVar9 = uVar11;
        if (Links(unsigned_short)::s_Sentinel == '\0') goto LAB_0048f998;
LAB_0048f54e:
        iVar3 = *(int *)(this + 4);
        if (uVar11 == 0xffff) goto LAB_0048f9cf;
LAB_0048f55b:
        puVar4 = (undefined2 *)(iVar3 + local_28);
      }
      bVar12 = Links(unsigned_short)::s_Sentinel == '\0';
      *(undefined2 *)(iVar3 + 6 + local_24) = puVar4[3];
      *(undefined2 *)(*(int *)(this + 4) + 6 + local_28) = 1;
      if ((bVar12) && (iVar3 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar3 != 0))
      {
        DAT_00f165d8 = 0xffff;
        Links(unsigned_short)::s_Sentinel = 0xffff;
        DAT_00f165da = 0xffff;
        __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        iVar3 = *(int *)(this + 4);
        if (uVar5 != 0xffff) goto LAB_0048f594;
LAB_00490110:
        puVar7 = &Links(unsigned_short)::s_Sentinel;
      }
      else {
        iVar3 = *(int *)(this + 4);
        if (uVar5 == 0xffff) goto LAB_00490110;
LAB_0048f594:
        puVar7 = (ushort *)(local_24 + iVar3);
      }
      *(undefined2 *)(iVar3 + 6 + (uint)*puVar7 * 0x10) = 1;
      RotateRight(this,uVar9);
      uVar2 = (uint)*(ushort *)(this + 0x10);
      uVar10 = uVar2;
    }
  }
  *(undefined2 *)(uVar10 * 0x10 + *(int *)(this + 4) + 6) = 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)