L L4D2node

CPhysicsCannister::TraceAttack

0x00788e20 · 219 bytes · __thiscall

_ZN17CPhysicsCannister11TraceAttackERK15CTakeDamageInfoRK6VectorP10CGameTrace

Decompiled

undefined (4 params)

/* CPhysicsCannister::TraceAttack(CTakeDamageInfo const&, Vector const&, CGameTrace*) */

void __thiscall
CPhysicsCannister::TraceAttack
          (CPhysicsCannister *this,CTakeDamageInfo *param_1,Vector *param_2,CGameTrace *param_3)

{
  uint uVar1;
  undefined *puVar2;
  Vector *local_30;
  uint local_28;
  uint local_24;
  float local_20;
  
  if ((this[0x1a74] == (CPhysicsCannister)0x0) && (*(int *)(param_3 + 0x44) != 0)) {
    local_24 = *(uint *)(param_2 + 4) ^ 0x80000000;
    local_28 = *(uint *)param_2 ^ 0x80000000;
    local_20 = -(*(float *)(param_2 + 8) + 5.0);
    VectorNormalize((Vector *)&local_28);
    local_30 = (Vector *)0x0;
    uVar1 = *(uint *)(param_1 + 0x34);
    if ((uVar1 != 0xffffffff) &&
       ((puVar2 = g_pEntityList + (uVar1 & 0xfff) * 0x10, puVar2 != (undefined *)0xfffffffc &&
        (*(uint *)(puVar2 + 8) == uVar1 >> 0xc)))) {
      local_30 = *(Vector **)(puVar2 + 4);
    }
    CannisterActivate((CBaseEntity *)this,local_30);
  }
  CBaseEntity::TraceAttack((CBaseEntity *)this,param_1,param_2,param_3);
  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)