L L4D2node

CBlood::BloodPosition

0x00670ed0 · 317 bytes · __cdecl

_ZN6CBlood13BloodPositionEP11CBaseEntity

Decompiled

undefined (1 param)

/* CBlood::BloodPosition(CBaseEntity*) */

CBaseEntity * CBlood::BloodPosition(CBaseEntity *param_1)

{
  char cVar1;
  longdouble lVar2;
  longdouble lVar3;
  longdouble lVar4;
  int in_stack_00000008;
  int *in_stack_0000000c;
  float local_28;
  float local_24;
  float local_20;
  
  if ((*(byte *)(in_stack_00000008 + 0x148) & 4) != 0) {
    if ((in_stack_0000000c == (int *)0x0) ||
       (cVar1 = (**(code **)(*in_stack_0000000c + 0x16c))(), cVar1 == '\0')) {
      in_stack_0000000c = (int *)UTIL_GetLocalPlayer();
      if (in_stack_0000000c != (int *)0x0) {
LAB_00670f16:
        lVar2 = (longdouble)(**(code **)(*random_valve + 4))(random_valve,0xc1200000,0x41200000);
        lVar3 = (longdouble)(**(code **)(*random_valve + 4))(random_valve,0xc1200000,0x41200000);
        lVar4 = (longdouble)(**(code **)(*random_valve + 4))(random_valve,0xc1200000,0x41200000);
        (**(code **)(*in_stack_0000000c + 0x234))(&local_28,in_stack_0000000c);
        *(float *)(param_1 + 4) = (float)lVar3 + local_24;
        *(float *)param_1 = (float)lVar4 + local_28;
        *(float *)(param_1 + 8) = (float)lVar2 + local_20;
        return param_1;
      }
    }
    else {
      cVar1 = (**(code **)(*in_stack_0000000c + 0x16c))();
      if (cVar1 != '\0') goto LAB_00670f16;
    }
  }
  *(undefined4 *)param_1 = *(undefined4 *)(in_stack_00000008 + 0x39c);
  *(undefined4 *)(param_1 + 4) = *(undefined4 *)(in_stack_00000008 + 0x3a0);
  *(undefined4 *)(param_1 + 8) = *(undefined4 *)(in_stack_00000008 + 0x3a4);
  return param_1;
}

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)