L L4D2node

CCSGameRules::DeathNotice

0x00433090 · 318 bytes · __thiscall

_ZN12CCSGameRules11DeathNoticeEP11CBasePlayerRK15CTakeDamageInfo

Decompiled

undefined (3 params)

/* CCSGameRules::DeathNotice(CBasePlayer*, CTakeDamageInfo const&) */

void __thiscall
CCSGameRules::DeathNotice(CCSGameRules *this,CBasePlayer *param_1,CTakeDamageInfo *param_2)

{
  uint uVar1;
  code *pcVar2;
  undefined4 uVar3;
  int *piVar4;
  undefined4 uVar5;
  undefined *puVar6;
  CBaseEntity *pCVar7;
  CBaseEntity *pCVar8;
  
  pCVar8 = (CBaseEntity *)0x0;
  uVar1 = *(uint *)(param_2 + 0x30);
  if (((uVar1 != 0xffffffff) &&
      (puVar6 = g_pEntityList + (uVar1 & 0xfff) * 0x10, puVar6 != (undefined *)0xfffffffc)) &&
     (*(uint *)(puVar6 + 8) == uVar1 >> 0xc)) {
    pCVar8 = *(CBaseEntity **)(puVar6 + 4);
  }
  uVar1 = *(uint *)(param_2 + 0x34);
  pCVar7 = (CBaseEntity *)0x0;
  if (((uVar1 != 0xffffffff) &&
      (puVar6 = g_pEntityList + (uVar1 & 0xfff) * 0x10, puVar6 != (undefined *)0xfffffffc)) &&
     (*(uint *)(puVar6 + 8) == uVar1 >> 0xc)) {
    pCVar7 = *(CBaseEntity **)(puVar6 + 4);
  }
  uVar3 = CMultiplayRules::GetDeathScorer((CMultiplayRules *)this,pCVar7,pCVar8);
  piVar4 = (int *)(**(code **)(*gameeventmanager + 0x1c))
                            (gameeventmanager,"player_death",0,&g_DeathNoticeEvent);
  if (piVar4 != (int *)0x0) {
    pcVar2 = *(code **)(*piVar4 + 0x30);
    uVar5 = (**(code **)(*engine + 0x40))(engine,*(undefined4 *)(param_1 + 0x30));
    (*pcVar2)(piVar4,"userid",uVar5);
    (**(code **)(*(int *)this + 0x290))(this,piVar4,uVar3,param_1,param_2);
                    /* WARNING: Could not recover jumptable at 0x004331b4. Too many branches */
                    /* WARNING: Treating indirect jump as call */
    (**(code **)(*gameeventmanager + 0x20))();
    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)