L L4D2node

CTerrorPlayer::UpdateHealingGnome

0x009a7da0 · 148 bytes · __thiscall

_ZN13CTerrorPlayer18UpdateHealingGnomeEv

Decompiled

undefined (1 param)

/* CTerrorPlayer::UpdateHealingGnome() */

void __thiscall CTerrorPlayer::UpdateHealingGnome(CTerrorPlayer *this)

{
  float fVar1;
  float fVar2;
  float fVar3;
  undefined4 uVar4;
  char cVar5;
  int iVar6;
  
  if (this[0x326a] != (CTerrorPlayer)0x0) {
    cVar5 = CDirectorChallengeMode::HealingGnome(*(CDirectorChallengeMode **)(TheDirector + 0x648));
    uVar4 = sv_healing_gnome_replenish_rate._28_4_;
    if ((cVar5 != '\0') && (fVar1 = *(float *)(this + 0x2a54), -1.0 < fVar1)) {
      fVar2 = *(float *)(gpGlobals + 0xc);
      *(float *)(this + 0x2a54) = fVar2;
      fVar3 = *(float *)(uVar4 + 0x2c);
      iVar6 = (**(code **)(*(int *)this + 0x1fc))(this);
      AddHealthBuffer(this,(fVar2 - fVar1) * fVar3,(float)iVar6);
      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)