L L4D2node

CUtlRBTree<CUtlMap<unsigned_long_long,PublishedFileInfo_t,unsigned_short>::Node_t,unsigned_short,CUtlMap<unsigned_long_long,PublishedFileInfo_t,unsigned_short>::CKeyLess,CUtlMemory<UtlRBTreeNode_t<CUtlMap<unsigned_long_long,PublishedFileInfo_t,unsigned_short>::Node_t,unsigned_short>,unsigned_short>>::RotateRight

0x0021ec20 · 1328 bytes · __thiscall

_ZN10CUtlRBTreeIN7CUtlMapIy19PublishedFileInfo_ttE6Node_tEtNS2_8CKeyLessE10CUtlMemoryI15UtlRBTreeNode_tIS3_tEtEE11RotateRightEt

Decompiled

undefined (2 params)

/* CUtlRBTree<CUtlMap<unsigned long long, PublishedFileInfo_t, unsigned short>::Node_t, unsigned
   short, CUtlMap<unsigned long long, PublishedFileInfo_t, unsigned short>::CKeyLess,
   CUtlMemory<UtlRBTreeNode_t<CUtlMap<unsigned long long, PublishedFileInfo_t, unsigned
   short>::Node_t, unsigned short>, unsigned short> >::RotateRight(unsigned short) */

void __thiscall
CUtlRBTree<CUtlMap<unsigned_long_long,PublishedFileInfo_t,unsigned_short>::Node_t,unsigned_short,CUtlMap<unsigned_long_long,PublishedFileInfo_t,unsigned_short>::CKeyLess,CUtlMemory<UtlRBTreeNode_t<CUtlMap<unsigned_long_long,PublishedFileInfo_t,unsigned_short>::Node_t,unsigned_short>,unsigned_short>>
::RotateRight(CUtlRBTree<CUtlMap<unsigned_long_long,PublishedFileInfo_t,unsigned_short>::Node_t,unsigned_short,CUtlMap<unsigned_long_long,PublishedFileInfo_t,unsigned_short>::CKeyLess,CUtlMemory<UtlRBTreeNode_t<CUtlMap<unsigned_long_long,PublishedFileInfo_t,unsigned_short>::Node_t,unsigned_short>,unsigned_short>>
              *this,ushort param_1)

{
  ushort uVar1;
  int iVar2;
  ushort uVar3;
  ushort *puVar4;
  undefined2 *puVar5;
  int iVar6;
  int local_24;
  
  if (Links(unsigned_short)::s_Sentinel == '\0') {
    iVar6 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
    if (iVar6 != 0) {
      Links(unsigned_short)::s_Sentinel = 0xffff;
      DAT_00341a9a = 0xffff;
      DAT_00341a9c = 0xffff;
      __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
    }
    if (param_1 != 0xffff) goto LAB_0021ec48;
LAB_0021ee45:
    local_24 = 0x253fdac0;
    puVar4 = &Links(unsigned_short)::s_Sentinel;
  }
  else {
    if (param_1 == 0xffff) goto LAB_0021ee45;
LAB_0021ec48:
    local_24 = (uint)param_1 * 0x2540;
    puVar4 = (ushort *)(*(int *)(this + 4) + local_24);
  }
  uVar1 = *puVar4;
  if ((Links(unsigned_short)::s_Sentinel == '\0') &&
     (iVar6 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar6 != 0)) {
    DAT_00341a9a = 0xffff;
    Links(unsigned_short)::s_Sentinel = 0xffff;
    DAT_00341a9c = 0xffff;
    __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
  }
  iVar6 = 0x253fdac0;
  puVar5 = &Links(unsigned_short)::s_Sentinel;
  if (uVar1 != 0xffff) {
    iVar6 = (uint)uVar1 * 0x2540;
    puVar5 = (undefined2 *)(*(int *)(this + 4) + iVar6);
  }
  *(undefined2 *)(*(int *)(this + 4) + local_24) = puVar5[1];
  if ((Links(unsigned_short)::s_Sentinel == '\0') &&
     (iVar2 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar2 != 0)) {
    DAT_00341a9a = 0xffff;
    Links(unsigned_short)::s_Sentinel = 0xffff;
    DAT_00341a9c = 0xffff;
    __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
  }
  if (uVar1 == 0xffff) {
    puVar5 = &Links(unsigned_short)::s_Sentinel;
  }
  else {
    puVar5 = (undefined2 *)(*(int *)(this + 4) + iVar6);
  }
  if (puVar5[1] != -1) {
    if ((Links(unsigned_short)::s_Sentinel == '\0') &&
       (iVar2 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar2 != 0)) {
      Links(unsigned_short)::s_Sentinel = 0xffff;
      DAT_00341a9a = 0xffff;
      DAT_00341a9c = 0xffff;
      __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
    }
    puVar5 = &Links(unsigned_short)::s_Sentinel;
    if (uVar1 != 0xffff) {
      puVar5 = (undefined2 *)(*(int *)(this + 4) + iVar6);
    }
    *(ushort *)(*(int *)(this + 4) + 4 + (uint)(ushort)puVar5[1] * 0x2540) = param_1;
  }
  if (uVar1 != 0xffff) {
    if ((Links(unsigned_short)::s_Sentinel == '\0') &&
       (iVar2 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar2 != 0)) {
      DAT_00341a9a = 0xffff;
      Links(unsigned_short)::s_Sentinel = 0xffff;
      DAT_00341a9c = 0xffff;
      __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
    }
    puVar5 = &Links(unsigned_short)::s_Sentinel;
    if (param_1 != 0xffff) {
      puVar5 = (undefined2 *)(*(int *)(this + 4) + local_24);
    }
    *(undefined2 *)(*(int *)(this + 4) + 4 + iVar6) = puVar5[2];
  }
  if (param_1 == *(ushort *)(this + 0x10)) {
    *(ushort *)(this + 0x10) = uVar1;
    goto LAB_0021ed9b;
  }
  if (Links(unsigned_short)::s_Sentinel == '\0') {
    iVar2 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
    if (iVar2 != 0) {
      Links(unsigned_short)::s_Sentinel = 0xffff;
      DAT_00341a9a = 0xffff;
      DAT_00341a9c = 0xffff;
      __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
      goto LAB_0021ed30;
    }
    if (param_1 != 0xffff) goto LAB_0021ed3a;
LAB_0021efc0:
    uVar3 = DAT_00341a9c;
    if (Links(unsigned_short)::s_Sentinel != '\0') goto LAB_0021ed4c;
LAB_0021efd8:
    iVar2 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel);
    if (iVar2 != 0) {
      Links(unsigned_short)::s_Sentinel = 0xffff;
      DAT_00341a9a = 0xffff;
      DAT_00341a9c = 0xffff;
      __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
      goto LAB_0021ed4c;
    }
    if (uVar3 != 0xffff) goto LAB_0021ed56;
LAB_0021f009:
    puVar5 = &Links(unsigned_short)::s_Sentinel;
  }
  else {
LAB_0021ed30:
    if (param_1 == 0xffff) goto LAB_0021efc0;
LAB_0021ed3a:
    uVar3 = *(ushort *)(local_24 + *(int *)(this + 4) + 4);
    if (Links(unsigned_short)::s_Sentinel == '\0') goto LAB_0021efd8;
LAB_0021ed4c:
    if (uVar3 == 0xffff) goto LAB_0021f009;
LAB_0021ed56:
    puVar5 = (undefined2 *)((uint)uVar3 * 0x2540 + *(int *)(this + 4));
  }
  if (param_1 == puVar5[1]) {
    if ((Links(unsigned_short)::s_Sentinel == '\0') &&
       (iVar2 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar2 != 0)) {
      DAT_00341a9a = 0xffff;
      Links(unsigned_short)::s_Sentinel = 0xffff;
      DAT_00341a9c = 0xffff;
      __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
    }
    puVar5 = &Links(unsigned_short)::s_Sentinel;
    if (param_1 != 0xffff) {
      puVar5 = (undefined2 *)(*(int *)(this + 4) + local_24);
    }
    *(ushort *)(*(int *)(this + 4) + 2 + (uint)(ushort)puVar5[2] * 0x2540) = uVar1;
  }
  else {
    if ((Links(unsigned_short)::s_Sentinel == '\0') &&
       (iVar2 = __cxa_guard_acquire(&Links(unsigned_short)::s_Sentinel), iVar2 != 0)) {
      DAT_00341a9a = 0xffff;
      Links(unsigned_short)::s_Sentinel = 0xffff;
      DAT_00341a9c = 0xffff;
      __cxa_guard_release(&Links(unsigned_short)::s_Sentinel);
    }
    puVar5 = &Links(unsigned_short)::s_Sentinel;
    if (param_1 != 0xffff) {
      puVar5 = (undefined2 *)(*(int *)(this + 4) + local_24);
    }
    *(ushort *)(*(int *)(this + 4) + (uint)(ushort)puVar5[2] * 0x2540) = uVar1;
  }
LAB_0021ed9b:
  *(ushort *)(*(int *)(this + 4) + 2 + iVar6) = param_1;
  if (param_1 != 0xffff) {
    *(ushort *)(*(int *)(this + 4) + 4 + local_24) = uVar1;
  }
  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)