L L4D2node

CUtlRBTree<CGameEvent,unsigned_short,bool(*)(CGameEvent_const&,CGameEvent_const&),CUtlMemory<UtlRBTreeNode_t<CGameEvent,unsigned_short>,unsigned_short>>::RemoveRebalance

0x006de8f0 · 5434 bytes · __thiscall

_ZN10CUtlRBTreeI10CGameEventtPFbRKS0_S2_E10CUtlMemoryI15UtlRBTreeNode_tIS0_tEtEE15RemoveRebalanceEt

Decompiled

undefined (2 params)

/* CUtlRBTree<CGameEvent, unsigned short, bool (*)(CGameEvent const&, CGameEvent const&),
   CUtlMemory<UtlRBTreeNode_t<CGameEvent, unsigned short>, unsigned short>
   >::RemoveRebalance(unsigned short) */

void __thiscall
CUtlRBTree<CGameEvent,unsigned_short,bool(*)(CGameEvent_const&,CGameEvent_const&),CUtlMemory<UtlRBTreeNode_t<CGameEvent,unsigned_short>,unsigned_short>>
::RemoveRebalance(CUtlRBTree<CGameEvent,unsigned_short,bool(*)(CGameEvent_const&,CGameEvent_const&),CUtlMemory<UtlRBTreeNode_t<CGameEvent,unsigned_short>,unsigned_short>>
                  *this,ushort param_1)

{
  short sVar1;
  ushort uVar2;
  ushort *puVar3;
  int iVar4;
  ushort uVar5;
  ushort uVar6;
  uint uVar7;
  undefined2 *puVar8;
  bool bVar9;
  int local_28;
  uint local_24;
  int local_20;
  
  uVar2 = *(ushort *)(this + 0x10);
  while (param_1 != uVar2) {
    if ((Links(unsigned_short)::s_Sentinel == '\0') &&
       (iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar4 != 0)) {
      DAT_00f3c854 = 0xffff;
      Links(unsigned_short)::s_Sentinel = 0xffff;
      DAT_00f3c852 = 0xffff;
      __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
    }
    sVar1 = DAT_00f3c856;
    if (param_1 != 0xffff) {
      sVar1 = *(short *)(*(int *)(this + 4) + (uint)param_1 * 0x14 + 6);
    }
    if (sVar1 != 1) break;
    if (Links(unsigned_short)::s_Sentinel == '\0') {
      iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
      if (iVar4 != 0) {
        Links(unsigned_short)::s_Sentinel = 0xffff;
        DAT_00f3c852 = 0xffff;
        DAT_00f3c854 = 0xffff;
        __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
      }
      if (param_1 != 0xffff) goto LAB_006de9dd;
LAB_006debc9:
      local_24 = (uint)DAT_00f3c854;
      uVar2 = DAT_00f3c854;
      if (Links(unsigned_short)::s_Sentinel != '\0') goto LAB_006de9fb;
LAB_006debe0:
      iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
      if (iVar4 != 0) {
        Links(unsigned_short)::s_Sentinel = 0xffff;
        DAT_00f3c852 = 0xffff;
        DAT_00f3c854 = 0xffff;
        __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
      }
      if (uVar2 != 0xffff) goto LAB_006dea05;
LAB_006dec05:
      if (param_1 != Links(unsigned_short)::s_Sentinel) goto LAB_006dea1e;
LAB_006dec20:
      if (Links(unsigned_short)::s_Sentinel == '\0') {
        iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
        if (iVar4 != 0) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f3c852 = 0xffff;
          DAT_00f3c854 = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        }
        if (uVar2 != 0xffff) goto LAB_006dec32;
LAB_006df4fd:
        puVar8 = &Links(unsigned_short)::s_Sentinel;
      }
      else {
        if (uVar2 == 0xffff) goto LAB_006df4fd;
LAB_006dec32:
        puVar8 = (undefined2 *)(*(int *)(this + 4) + local_24 * 0x14);
      }
      uVar6 = puVar8[1];
      uVar7 = (uint)uVar6;
      if ((Links(unsigned_short)::s_Sentinel == '\0') &&
         (iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar4 != 0)) {
        DAT_00f3c852 = 0xffff;
        Links(unsigned_short)::s_Sentinel = 0xffff;
        DAT_00f3c854 = 0xffff;
        __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        if (uVar6 != 0xffff) goto LAB_006dec54;
LAB_006df4c8:
        puVar8 = &Links(unsigned_short)::s_Sentinel;
      }
      else {
        if (uVar6 == 0xffff) goto LAB_006df4c8;
LAB_006dec54:
        puVar8 = (undefined2 *)(*(int *)(this + 4) + uVar7 * 0x14);
      }
      if (puVar8[3] == 0) {
        *(undefined2 *)(*(int *)(this + 4) + uVar7 * 0x14 + 6) = 1;
        *(undefined2 *)(*(int *)(this + 4) + local_24 * 0x14 + 6) = 0;
        RotateLeft(this,(ushort)local_24);
        if (Links(unsigned_short)::s_Sentinel == '\0') {
          iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
          if (iVar4 != 0) {
            Links(unsigned_short)::s_Sentinel = 0xffff;
            DAT_00f3c852 = 0xffff;
            DAT_00f3c854 = 0xffff;
            __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          }
          if (param_1 != 0xffff) goto LAB_006df438;
LAB_006df8e9:
          puVar8 = &Links(unsigned_short)::s_Sentinel;
        }
        else {
          if (param_1 == 0xffff) goto LAB_006df8e9;
LAB_006df438:
          puVar8 = (undefined2 *)(*(int *)(this + 4) + (uint)param_1 * 0x14);
        }
        uVar2 = puVar8[2];
        if (Links(unsigned_short)::s_Sentinel == '\0') {
          iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
          if (iVar4 != 0) {
            Links(unsigned_short)::s_Sentinel = 0xffff;
            DAT_00f3c852 = 0xffff;
            DAT_00f3c854 = 0xffff;
            __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          }
          if (uVar2 != 0xffff) goto LAB_006df45a;
LAB_006df8ad:
          puVar8 = &Links(unsigned_short)::s_Sentinel;
        }
        else {
          if (uVar2 == 0xffff) goto LAB_006df8ad;
LAB_006df45a:
          puVar8 = (undefined2 *)(*(int *)(this + 4) + (uint)uVar2 * 0x14);
        }
        uVar7 = (uint)(ushort)puVar8[1];
      }
      uVar6 = (ushort)uVar7;
      if (Links(unsigned_short)::s_Sentinel == '\0') {
        iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
        if (iVar4 != 0) {
          DAT_00f3c852 = 0xffff;
          DAT_00f3c854 = 0xffff;
          Links(unsigned_short)::s_Sentinel = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          goto LAB_006dec7a;
        }
        if (uVar6 != 0xffff) goto LAB_006dec84;
LAB_006df3db:
        puVar3 = &Links(unsigned_short)::s_Sentinel;
      }
      else {
LAB_006dec7a:
        if (uVar6 == 0xffff) goto LAB_006df3db;
LAB_006dec84:
        puVar3 = (ushort *)(*(int *)(this + 4) + uVar7 * 0x14);
      }
      uVar5 = *puVar3;
      if (Links(unsigned_short)::s_Sentinel == '\0') {
        iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
        if (iVar4 != 0) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f3c852 = 0xffff;
          DAT_00f3c854 = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          goto LAB_006dec9b;
        }
        if (uVar5 != 0xffff) goto LAB_006deca5;
LAB_006df1bb:
        if (DAT_00f3c856 != 1) goto joined_r0x006df21c;
LAB_006df1cb:
        if ((Links(unsigned_short)::s_Sentinel == '\0') &&
           (iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar4 != 0)) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f3c852 = 0xffff;
          DAT_00f3c854 = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        }
        if (uVar6 == 0xffff) {
          puVar8 = &Links(unsigned_short)::s_Sentinel;
        }
        else {
          puVar8 = (undefined2 *)(*(int *)(this + 4) + uVar7 * 0x14);
        }
        uVar5 = puVar8[1];
        if ((Links(unsigned_short)::s_Sentinel == '\0') &&
           (iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar4 != 0)) {
          DAT_00f3c852 = 0xffff;
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f3c854 = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        }
        if (uVar5 == 0xffff) {
          puVar8 = &Links(unsigned_short)::s_Sentinel;
        }
        else {
          puVar8 = (undefined2 *)(*(int *)(this + 4) + (uint)uVar5 * 0x14);
        }
        if (puVar8[3] != 1) goto joined_r0x006df21c;
LAB_006df6b0:
        param_1 = uVar2;
        if ((short)uVar7 == -1) {
          uVar2 = *(ushort *)(this + 0x10);
        }
        else {
          *(undefined2 *)(*(int *)(this + 4) + uVar7 * 0x14 + 6) = 0;
          uVar2 = *(ushort *)(this + 0x10);
        }
      }
      else {
LAB_006dec9b:
        if (uVar5 == 0xffff) goto LAB_006df1bb;
LAB_006deca5:
        if (*(short *)(*(int *)(this + 4) + (uint)uVar5 * 0x14 + 6) == 1) goto LAB_006df1cb;
joined_r0x006df21c:
        if (Links(unsigned_short)::s_Sentinel == '\0') {
          iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
          if (iVar4 != 0) {
            Links(unsigned_short)::s_Sentinel = 0xffff;
            DAT_00f3c852 = 0xffff;
            DAT_00f3c854 = 0xffff;
            __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
            goto LAB_006decc1;
          }
          if (uVar6 != 0xffff) goto LAB_006deccb;
LAB_006df253:
          local_28 = 0x13ffec;
          uVar7 = (uint)DAT_00f3c852;
          if (Links(unsigned_short)::s_Sentinel != '\0') goto LAB_006decec;
LAB_006df26b:
          iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
          if (iVar4 != 0) {
            Links(unsigned_short)::s_Sentinel = 0xffff;
            DAT_00f3c852 = 0xffff;
            DAT_00f3c854 = 0xffff;
            __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
            goto LAB_006decec;
          }
          if ((short)uVar7 != -1) goto LAB_006decf6;
LAB_006df296:
          if (DAT_00f3c856 != 1) goto LAB_006ded0a;
LAB_006df2b0:
          if ((Links(unsigned_short)::s_Sentinel == '\0') &&
             (iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar4 != 0)) {
            Links(unsigned_short)::s_Sentinel = 0xffff;
            DAT_00f3c852 = 0xffff;
            DAT_00f3c854 = 0xffff;
            __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          }
          puVar3 = &Links(unsigned_short)::s_Sentinel;
          if (uVar6 != 0xffff) {
            puVar3 = (ushort *)(local_28 + *(int *)(this + 4));
          }
          *(undefined2 *)(*(int *)(this + 4) + 6 + (uint)*puVar3 * 0x14) = 1;
          *(undefined2 *)(*(int *)(this + 4) + 6 + local_28) = 0;
          RotateRight(this,uVar6);
          if ((Links(unsigned_short)::s_Sentinel == '\0') &&
             (iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar4 != 0)) {
            Links(unsigned_short)::s_Sentinel = 0xffff;
            DAT_00f3c852 = 0xffff;
            DAT_00f3c854 = 0xffff;
            __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          }
          if (param_1 == 0xffff) {
            puVar8 = &Links(unsigned_short)::s_Sentinel;
          }
          else {
            puVar8 = (undefined2 *)(*(int *)(this + 4) + (uint)param_1 * 0x14);
          }
          uVar2 = puVar8[2];
          if ((Links(unsigned_short)::s_Sentinel == '\0') &&
             (iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar4 != 0)) {
            Links(unsigned_short)::s_Sentinel = 0xffff;
            DAT_00f3c852 = 0xffff;
            DAT_00f3c854 = 0xffff;
            __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          }
          if (uVar2 == 0xffff) {
            local_20 = 0x13ffec;
            puVar8 = &Links(unsigned_short)::s_Sentinel;
            local_24._0_2_ = 0xffff;
          }
          else {
            local_20 = (uint)uVar2 * 0x14;
            puVar8 = (undefined2 *)(*(int *)(this + 4) + local_20);
            local_24._0_2_ = uVar2;
          }
          uVar6 = puVar8[1];
          local_28 = (uint)uVar6 * 0x14;
          if (Links(unsigned_short)::s_Sentinel == '\0') goto LAB_006df370;
LAB_006ded25:
          iVar4 = *(int *)(this + 4);
          if (uVar2 != 0xffff) goto LAB_006ded32;
LAB_006df39e:
          puVar8 = &Links(unsigned_short)::s_Sentinel;
        }
        else {
LAB_006decc1:
          if (uVar6 == 0xffff) goto LAB_006df253;
LAB_006deccb:
          local_28 = uVar7 * 0x14;
          uVar7 = (uint)*(ushort *)(*(int *)(this + 4) + local_28 + 2);
          if (Links(unsigned_short)::s_Sentinel == '\0') goto LAB_006df26b;
LAB_006decec:
          if ((short)uVar7 == -1) goto LAB_006df296;
LAB_006decf6:
          if (*(short *)(*(int *)(this + 4) + uVar7 * 0x14 + 6) == 1) goto LAB_006df2b0;
LAB_006ded0a:
          local_20 = (uint)uVar2 * 0x14;
          local_24._0_2_ = uVar2;
          if (Links(unsigned_short)::s_Sentinel != '\0') goto LAB_006ded25;
LAB_006df370:
          iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
          if (iVar4 != 0) {
            Links(unsigned_short)::s_Sentinel = 0xffff;
            DAT_00f3c852 = 0xffff;
            DAT_00f3c854 = 0xffff;
            __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
            goto LAB_006ded25;
          }
          iVar4 = *(int *)(this + 4);
          if (uVar2 == 0xffff) goto LAB_006df39e;
LAB_006ded32:
          puVar8 = (undefined2 *)(local_20 + iVar4);
        }
        bVar9 = Links(unsigned_short)::s_Sentinel == '\0';
        *(undefined2 *)(iVar4 + 6 + local_28) = puVar8[3];
        *(undefined2 *)(*(int *)(this + 4) + 6 + local_20) = 1;
        if ((bVar9) && (iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar4 != 0)
           ) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f3c852 = 0xffff;
          DAT_00f3c854 = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        }
        if (uVar6 == 0xffff) {
          puVar8 = &Links(unsigned_short)::s_Sentinel;
        }
        else {
          puVar8 = (undefined2 *)(local_28 + *(int *)(this + 4));
        }
        *(undefined2 *)(*(int *)(this + 4) + 6 + (uint)(ushort)puVar8[1] * 0x14) = 1;
        RotateLeft(this,(ushort)local_24);
        uVar2 = *(ushort *)(this + 0x10);
        param_1 = uVar2;
      }
    }
    else {
      if (param_1 == 0xffff) goto LAB_006debc9;
LAB_006de9dd:
      uVar2 = *(ushort *)(*(int *)(this + 4) + (uint)param_1 * 0x14 + 4);
      local_24 = (uint)uVar2;
      if (Links(unsigned_short)::s_Sentinel == '\0') goto LAB_006debe0;
LAB_006de9fb:
      if (uVar2 == 0xffff) goto LAB_006dec05;
LAB_006dea05:
      if (param_1 == *(ushort *)(*(int *)(this + 4) + local_24 * 0x14)) goto LAB_006dec20;
LAB_006dea1e:
      if (Links(unsigned_short)::s_Sentinel == '\0') {
        iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
        if (iVar4 != 0) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f3c852 = 0xffff;
          DAT_00f3c854 = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        }
        if (uVar2 != 0xffff) goto LAB_006dea30;
LAB_006df115:
        puVar3 = &Links(unsigned_short)::s_Sentinel;
      }
      else {
        if (uVar2 == 0xffff) goto LAB_006df115;
LAB_006dea30:
        puVar3 = (ushort *)(*(int *)(this + 4) + local_24 * 0x14);
      }
      uVar6 = *puVar3;
      uVar7 = (uint)uVar6;
      if ((Links(unsigned_short)::s_Sentinel == '\0') &&
         (iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar4 != 0)) {
        Links(unsigned_short)::s_Sentinel = 0xffff;
        DAT_00f3c852 = 0xffff;
        DAT_00f3c854 = 0xffff;
        __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        if (uVar6 != 0xffff) goto LAB_006dea51;
LAB_006df020:
        if (DAT_00f3c856 != 0) goto LAB_006dea68;
LAB_006df030:
        *(undefined2 *)(*(int *)(this + 4) + uVar7 * 0x14 + 6) = 1;
        *(undefined2 *)(*(int *)(this + 4) + local_24 * 0x14 + 6) = 0;
        RotateRight(this,(ushort)local_24);
        if (Links(unsigned_short)::s_Sentinel == '\0') {
          iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
          if (iVar4 != 0) {
            Links(unsigned_short)::s_Sentinel = 0xffff;
            DAT_00f3c852 = 0xffff;
            DAT_00f3c854 = 0xffff;
            __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          }
          if (param_1 != 0xffff) goto LAB_006df080;
LAB_006df569:
          puVar8 = &Links(unsigned_short)::s_Sentinel;
        }
        else {
          if (param_1 == 0xffff) goto LAB_006df569;
LAB_006df080:
          puVar8 = (undefined2 *)(*(int *)(this + 4) + (uint)param_1 * 0x14);
        }
        uVar2 = puVar8[2];
        if (Links(unsigned_short)::s_Sentinel == '\0') {
          iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
          if (iVar4 != 0) {
            Links(unsigned_short)::s_Sentinel = 0xffff;
            DAT_00f3c852 = 0xffff;
            DAT_00f3c854 = 0xffff;
            __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          }
          if (uVar2 != 0xffff) goto LAB_006df0a2;
LAB_006df535:
          puVar3 = &Links(unsigned_short)::s_Sentinel;
        }
        else {
          if (uVar2 == 0xffff) goto LAB_006df535;
LAB_006df0a2:
          puVar3 = (ushort *)(*(int *)(this + 4) + (uint)uVar2 * 0x14);
        }
        uVar7 = (uint)*puVar3;
        if (Links(unsigned_short)::s_Sentinel != '\0') goto LAB_006dea77;
LAB_006df0b9:
        iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
        if (iVar4 != 0) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f3c852 = 0xffff;
          DAT_00f3c854 = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          goto LAB_006dea77;
        }
        if ((short)uVar7 != -1) goto LAB_006dea81;
LAB_006df0e4:
        puVar8 = &Links(unsigned_short)::s_Sentinel;
      }
      else {
        if (uVar6 == 0xffff) goto LAB_006df020;
LAB_006dea51:
        if (*(short *)(*(int *)(this + 4) + uVar7 * 0x14 + 6) == 0) goto LAB_006df030;
LAB_006dea68:
        if (Links(unsigned_short)::s_Sentinel == '\0') goto LAB_006df0b9;
LAB_006dea77:
        if ((short)uVar7 == -1) goto LAB_006df0e4;
LAB_006dea81:
        puVar8 = (undefined2 *)(*(int *)(this + 4) + uVar7 * 0x14);
      }
      uVar6 = puVar8[1];
      uVar5 = (ushort)uVar7;
      if (Links(unsigned_short)::s_Sentinel == '\0') {
        iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
        if (iVar4 != 0) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f3c854 = 0xffff;
          DAT_00f3c852 = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          goto LAB_006dea99;
        }
        if (uVar6 != 0xffff) goto LAB_006deaa3;
LAB_006dedcb:
        if (DAT_00f3c856 != 1) goto LAB_006deab7;
LAB_006dede0:
        if ((Links(unsigned_short)::s_Sentinel == '\0') &&
           (iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar4 != 0)) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f3c852 = 0xffff;
          DAT_00f3c854 = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        }
        uVar6 = Links(unsigned_short)::s_Sentinel;
        if (uVar5 != 0xffff) {
          uVar6 = *(ushort *)(*(int *)(this + 4) + uVar7 * 0x14);
        }
        if ((Links(unsigned_short)::s_Sentinel == '\0') &&
           (iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar4 != 0)) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f3c852 = 0xffff;
          DAT_00f3c854 = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        }
        if (uVar6 == 0xffff) {
          puVar8 = &Links(unsigned_short)::s_Sentinel;
        }
        else {
          puVar8 = (undefined2 *)(*(int *)(this + 4) + (uint)uVar6 * 0x14);
        }
        if (puVar8[3] == 1) goto LAB_006df6b0;
        if (Links(unsigned_short)::s_Sentinel == '\0') goto LAB_006dee40;
LAB_006deabf:
        if (uVar5 != 0xffff) goto LAB_006deac9;
LAB_006dee6b:
        local_28 = 0x13ffec;
        uVar7 = (uint)Links(unsigned_short)::s_Sentinel;
        if (Links(unsigned_short)::s_Sentinel == '\0') goto LAB_006dee88;
LAB_006deae9:
        if ((short)uVar7 != -1) goto LAB_006deaf3;
LAB_006deeb3:
        if (DAT_00f3c856 != 1) goto LAB_006deb07;
LAB_006deec8:
        if ((Links(unsigned_short)::s_Sentinel == '\0') &&
           (iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar4 != 0)) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f3c852 = 0xffff;
          DAT_00f3c854 = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        }
        puVar8 = &Links(unsigned_short)::s_Sentinel;
        if (uVar5 != 0xffff) {
          puVar8 = (undefined2 *)(local_28 + *(int *)(this + 4));
        }
        *(undefined2 *)(*(int *)(this + 4) + 6 + (uint)(ushort)puVar8[1] * 0x14) = 1;
        *(undefined2 *)(*(int *)(this + 4) + 6 + local_28) = 0;
        RotateLeft(this,uVar5);
        if ((Links(unsigned_short)::s_Sentinel == '\0') &&
           (iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar4 != 0)) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f3c852 = 0xffff;
          DAT_00f3c854 = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        }
        if (param_1 == 0xffff) {
          puVar8 = &Links(unsigned_short)::s_Sentinel;
        }
        else {
          puVar8 = (undefined2 *)(*(int *)(this + 4) + (uint)param_1 * 0x14);
        }
        uVar2 = puVar8[2];
        if ((Links(unsigned_short)::s_Sentinel == '\0') &&
           (iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar4 != 0)) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f3c852 = 0xffff;
          DAT_00f3c854 = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        }
        if (uVar2 == 0xffff) {
          local_20 = 0x13ffec;
          puVar3 = &Links(unsigned_short)::s_Sentinel;
          local_24._0_2_ = 0xffff;
        }
        else {
          local_20 = (uint)uVar2 * 0x14;
          puVar3 = (ushort *)(*(int *)(this + 4) + local_20);
          local_24._0_2_ = uVar2;
        }
        uVar5 = *puVar3;
        local_28 = (uint)uVar5 * 0x14;
        if (Links(unsigned_short)::s_Sentinel != '\0') goto LAB_006deb22;
LAB_006def88:
        iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
        if (iVar4 != 0) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f3c852 = 0xffff;
          DAT_00f3c854 = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          goto LAB_006deb22;
        }
        iVar4 = *(int *)(this + 4);
        if (uVar2 != 0xffff) goto LAB_006deb2f;
LAB_006defb6:
        puVar8 = &Links(unsigned_short)::s_Sentinel;
      }
      else {
LAB_006dea99:
        if (uVar6 == 0xffff) goto LAB_006dedcb;
LAB_006deaa3:
        if (*(short *)(*(int *)(this + 4) + (uint)uVar6 * 0x14 + 6) == 1) goto LAB_006dede0;
LAB_006deab7:
        if (Links(unsigned_short)::s_Sentinel != '\0') goto LAB_006deabf;
LAB_006dee40:
        iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
        if (iVar4 != 0) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f3c852 = 0xffff;
          DAT_00f3c854 = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          goto LAB_006deabf;
        }
        if (uVar5 == 0xffff) goto LAB_006dee6b;
LAB_006deac9:
        local_28 = uVar7 * 0x14;
        uVar7 = (uint)*(ushort *)(*(int *)(this + 4) + local_28);
        if (Links(unsigned_short)::s_Sentinel != '\0') goto LAB_006deae9;
LAB_006dee88:
        iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
        if (iVar4 != 0) {
          Links(unsigned_short)::s_Sentinel = 0xffff;
          DAT_00f3c852 = 0xffff;
          DAT_00f3c854 = 0xffff;
          __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
          goto LAB_006deae9;
        }
        if ((short)uVar7 == -1) goto LAB_006deeb3;
LAB_006deaf3:
        if (*(short *)(*(int *)(this + 4) + uVar7 * 0x14 + 6) == 1) goto LAB_006deec8;
LAB_006deb07:
        local_20 = (uint)uVar2 * 0x14;
        local_24._0_2_ = uVar2;
        if (Links(unsigned_short)::s_Sentinel == '\0') goto LAB_006def88;
LAB_006deb22:
        iVar4 = *(int *)(this + 4);
        if (uVar2 == 0xffff) goto LAB_006defb6;
LAB_006deb2f:
        puVar8 = (undefined2 *)(local_20 + iVar4);
      }
      bVar9 = Links(unsigned_short)::s_Sentinel == '\0';
      *(undefined2 *)(iVar4 + 6 + local_28) = puVar8[3];
      *(undefined2 *)(*(int *)(this + 4) + 6 + local_20) = 1;
      if ((bVar9) && (iVar4 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar4 != 0))
      {
        Links(unsigned_short)::s_Sentinel = 0xffff;
        DAT_00f3c852 = 0xffff;
        DAT_00f3c854 = 0xffff;
        __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
        iVar4 = *(int *)(this + 4);
        if (uVar5 != 0xffff) goto LAB_006deb65;
LAB_006df6a0:
        puVar3 = &Links(unsigned_short)::s_Sentinel;
      }
      else {
        iVar4 = *(int *)(this + 4);
        if (uVar5 == 0xffff) goto LAB_006df6a0;
LAB_006deb65:
        puVar3 = (ushort *)(local_28 + iVar4);
      }
      *(undefined2 *)(iVar4 + 6 + (uint)*puVar3 * 0x14) = 1;
      RotateRight(this,(ushort)local_24);
      uVar2 = *(ushort *)(this + 0x10);
      param_1 = uVar2;
    }
  }
  *(undefined2 *)(*(int *)(this + 4) + (uint)param_1 * 0x14 + 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)