L L4D2node

CGameScore::Use

0x006f2240 · 136 bytes · __cdecl

_ZN10CGameScore3UseEP11CBaseEntityS1_8USE_TYPEf

Decompiled

undefined (4 params)

/* CGameScore::Use(CBaseEntity*, CBaseEntity*, USE_TYPE, float) */

void CGameScore::Use(int param_1,CBaseEntity *param_2_00)

{
  CBaseEntity *pCVar1;
  char cVar2;
  bool param_2;
  
  pCVar1 = _param_2;
  if ((*(int *)(param_1 + 0x440) != 0) &&
     (cVar2 = UTIL_IsMasterTriggered(*(undefined4 *)(param_1 + 0x440),_param_2), cVar2 == '\0')) {
    return;
  }
  cVar2 = (**(code **)(*(int *)_param_2 + 0x16c))(_param_2);
  if (cVar2 == '\0') {
    return;
  }
  if ((*(uint *)(param_1 + 0x148) & 2) != 0) {
    param_2 = SUB41(*(undefined4 *)(param_1 + 0x444),0);
    CBaseEntity::AddPointsToTeam((int)pCVar1,param_2);
    return;
  }
  CBaseEntity::AddPoints
            (_param_2,*(int *)(param_1 + 0x444),(bool)((byte)*(uint *)(param_1 + 0x148) & 1));
  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)