L L4D2node

CFirstAidKit::ShouldStartAction

0x00536f00 · 95 bytes · __cdecl

_ZN12CFirstAidKit17ShouldStartActionEN17CBaseBackpackItem22BackpackItemActionTypeEP13CTerrorPlayerP11CBaseEntity

Decompiled

undefined (3 params)

/* CFirstAidKit::ShouldStartAction(CBaseBackpackItem::BackpackItemActionType, CTerrorPlayer*,
   CBaseEntity*) */

undefined4 CFirstAidKit::ShouldStartAction(void)

{
  char cVar1;
  undefined4 uVar2;
  int *in_stack_00000010;
  
  cVar1 = (**(code **)(*in_stack_00000010 + 0x16c))(in_stack_00000010);
  if ((cVar1 != '\0') && (in_stack_00000010[0x40] < *(int *)(FirstAidKitMaxHeal._28_4_ + 0x30) + -1)
     ) {
    uVar2 = CBaseBackpackItem::ShouldStartAction();
    return uVar2;
  }
  return 0;
}

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)