L L4D2node

CHunterClaw::GetPlayerDamage

0x0053ea60 · 97 bytes · __thiscall

_ZNK11CHunterClaw15GetPlayerDamageEP13CTerrorPlayer

Decompiled

undefined (2 params)

/* CHunterClaw::GetPlayerDamage(CTerrorPlayer*) const */

longdouble __thiscall CHunterClaw::GetPlayerDamage(CHunterClaw *this,CTerrorPlayer *param_1)

{
  char cVar1;
  int iVar2;
  longdouble lVar3;
  
  iVar2 = CTerrorWeapon::GetPlayerOwner((CTerrorWeapon *)this);
  if (iVar2 == 0) {
    lVar3 = (longdouble)CDirector::GetZombieAttackDamage(TheDirector,param_1);
    return lVar3;
  }
  cVar1 = CTerrorGameRules::HasPlayerControlledZombies();
  if (cVar1 != '\0') {
    return (longdouble)*(float *)(hunter_pz_claw_dmg._28_4_ + 0x2c);
  }
  lVar3 = (longdouble)CDirector::GetHunterAttackDamage();
  return lVar3;
}

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)