L L4D2node

CUtlLinkedList<CAI_Concept,unsigned_short,false,unsigned_int,CUtlMemory<UtlLinkedListElem_t<CAI_Concept,unsigned_short>,unsigned_int>>::Unlink

0x005c14d0 · 132 bytes · __thiscall

_ZN14CUtlLinkedListI11CAI_ConcepttLb0Ej10CUtlMemoryI19UtlLinkedListElem_tIS0_tEjEE6UnlinkEj

Decompiled

undefined (2 params)

/* CUtlLinkedList<CAI_Concept, unsigned short, false, unsigned int,
   CUtlMemory<UtlLinkedListElem_t<CAI_Concept, unsigned short>, unsigned int> >::Unlink(unsigned
   int) */

void __thiscall
CUtlLinkedList<CAI_Concept,unsigned_short,false,unsigned_int,CUtlMemory<UtlLinkedListElem_t<CAI_Concept,unsigned_short>,unsigned_int>>
::Unlink(CUtlLinkedList<CAI_Concept,unsigned_short,false,unsigned_int,CUtlMemory<UtlLinkedListElem_t<CAI_Concept,unsigned_short>,unsigned_int>>
         *this,uint param_1)

{
  int iVar1;
  ushort uVar2;
  
  if ((int)param_1 < 0) {
    return;
  }
  if (*(int *)(this + 4) <= (int)param_1) {
    return;
  }
  if (*(uint *)(this + 0x20) < param_1) {
    return;
  }
  iVar1 = *(int *)this + param_1 * 0xc;
  uVar2 = *(ushort *)(iVar1 + 8);
  if (param_1 != uVar2) {
    if (uVar2 == 0xffff) {
      *(uint *)(this + 0xc) = (uint)*(ushort *)(iVar1 + 10);
      uVar2 = *(ushort *)(iVar1 + 10);
    }
    else {
      *(undefined2 *)(*(int *)this + 10 + (uint)uVar2 * 0xc) = *(undefined2 *)(iVar1 + 10);
      uVar2 = *(ushort *)(iVar1 + 10);
    }
    if (uVar2 == 0xffff) {
      *(uint *)(this + 0x10) = (uint)*(ushort *)(iVar1 + 8);
    }
    else {
      *(undefined2 *)(*(int *)this + (uint)uVar2 * 0xc + 8) = *(undefined2 *)(iVar1 + 8);
    }
    *(short *)(iVar1 + 10) = (short)param_1;
    *(short *)(iVar1 + 8) = (short)param_1;
    *(int *)(this + 0x18) = *(int *)(this + 0x18) + -1;
    return;
  }
  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)