L L4D2node

CHunterClaw::OnLungedPlayer

0x0053ee70 · 317 bytes · __thiscall

_ZN11CHunterClaw14OnLungedPlayerEv

Decompiled

undefined (1 param)

/* CHunterClaw::OnLungedPlayer() */

void __thiscall CHunterClaw::OnLungedPlayer(CHunterClaw *this)

{
  uint uVar1;
  int iVar2;
  undefined *puVar3;
  longdouble lVar4;
  
  iVar2 = CTerrorWeapon::GetPlayerOwner((CTerrorWeapon *)this);
  if (iVar2 != 0) {
    iVar2 = CTerrorWeapon::GetPlayerOwner((CTerrorWeapon *)this);
    if (*(char *)(iVar2 + 0x3e78) != '\0') {
      return;
    }
    iVar2 = CTerrorWeapon::GetPlayerOwner((CTerrorWeapon *)this);
    uVar1 = *(uint *)(iVar2 + 0x3e64);
    if ((((uVar1 != 0xffffffff) &&
         (puVar3 = g_pEntityList + (uVar1 & 0xfff) * 0x10, puVar3 != (undefined *)0xfffffffc)) &&
        (*(uint *)(puVar3 + 8) == uVar1 >> 0xc)) && (*(int *)(puVar3 + 4) != 0)) {
      return;
    }
  }
  lVar4 = (longdouble)CountdownTimer::Now();
  if ((float)lVar4 < *(float *)(this + 0x17e4)) {
    return;
  }
  lVar4 = (longdouble)CountdownTimer::Now();
  if ((float)lVar4 + 1.0 != *(float *)(this + 0x17e4)) {
    (**(code **)(*(int *)(this + 0x17dc) + 4))(this + 0x17dc,this + 0x17e4);
    *(float *)(this + 0x17e4) = (float)lVar4 + 1.0;
  }
  if (*(float *)(this + 0x17e0) != 1.0) {
    (**(code **)(*(int *)(this + 0x17dc) + 4))(this + 0x17dc,this + 0x17e0);
    *(undefined4 *)(this + 0x17e0) = 0x3f800000;
  }
  (**(code **)(*(int *)this + 0x3f0))(this,0x321);
  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)