L L4D2node

CStudioHdr::SetAttachmentBone

0x000e27a0 · 71 bytes · __thiscall

_ZN10CStudioHdr17SetAttachmentBoneEii

Decompiled

undefined (3 params)

/* CStudioHdr::SetAttachmentBone(int, int) */

void __thiscall CStudioHdr::SetAttachmentBone(CStudioHdr *this,int param_1,int param_2)

{
  int iVar1;
  int iVar2;
  
  iVar2 = studiohdr_t::pAttachment(*(studiohdr_t **)this,param_1);
  iVar1 = *(int *)(this + 4);
  if (iVar1 != 0) {
    param_2 = *(int *)(*(int *)(*(int *)(*(int *)(iVar1 + 0x30) + param_1 * 8) * 0x90 +
                                *(int *)(iVar1 + 0x58) + 4) + param_2 * 4);
  }
  *(int *)(iVar2 + 8) = param_2;
  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)