CBaseCSGrenadeProjectile::Splash
0x0042cfd0 · 1009 bytes · __thiscall
_ZN24CBaseCSGrenadeProjectile6SplashEv
Decompiled
undefined (1 param)
/* CBaseCSGrenadeProjectile::Splash() */
void __thiscall CBaseCSGrenadeProjectile::Splash(CBaseCSGrenadeProjectile *this)
{
uint uVar1;
longdouble lVar2;
undefined4 local_f8;
undefined4 local_f4;
float local_f0;
CTraceFilterSimple local_e0 [16];
Vector local_d0 [12];
undefined4 local_c4;
undefined4 local_c0;
float local_bc;
float local_a4;
char local_99;
float local_98;
undefined4 local_7c;
undefined4 local_78;
float local_74;
undefined4 local_70;
undefined4 local_6c;
undefined4 local_68;
undefined4 local_64;
undefined4 local_60;
undefined4 local_5c;
undefined4 local_58;
undefined4 local_54;
undefined4 local_50;
uint local_4c;
undefined4 local_48;
float local_44;
undefined4 local_40;
undefined4 local_3c;
undefined4 local_38;
undefined2 local_34;
undefined4 local_30;
undefined4 local_2c;
undefined4 local_28;
undefined1 local_24;
undefined1 local_23;
if (((byte)this[0x14d] & 8) != 0) {
CBaseEntity::CalcAbsolutePosition((CBaseEntity *)this);
}
local_f4 = *(undefined4 *)(this + 0x2e0);
local_6c = 0;
local_f8 = *(undefined4 *)(this + 0x2e4);
local_38 = CONCAT22(local_38._2_2_,0x100);
local_f0 = *(float *)(this + 0x2e8);
local_68 = 0;
local_64 = 0x44000000;
local_44 = 0.0;
local_48 = 0;
local_4c = 0;
local_3c = 0;
local_38 = CONCAT31(local_38._1_3_,1);
local_54 = 0;
local_58 = 0;
local_5c = 0;
local_7c = local_f4;
local_78 = local_f8;
local_74 = local_f0;
CTraceFilterSimple::CTraceFilterSimple
(local_e0,(IHandleEntity *)0x0,0,(_func_bool_IHandleEntity_ptr_int *)0x0);
(**(code **)(*enginetrace + 0x14))(enginetrace,(CEffectData *)&local_7c,0x4030,local_e0,local_d0);
if (*(int *)(r_visualizetraces._28_4_ + 0x30) != 0) {
DebugDrawLine(local_d0,(Vector *)&local_c4,0xff,0,0,true,-1.0);
}
if (local_99 == '\0') {
local_6c = 0;
local_68 = 0;
local_64 = 0xc4000000;
local_38 = CONCAT22(local_38._2_2_,0x100);
local_44 = 0.0;
local_48 = 0;
local_4c = 0;
local_3c = 0;
local_38 = CONCAT31(local_38._1_3_,1);
local_54 = 0;
local_58 = 0;
local_5c = 0;
local_7c = local_f4;
local_78 = local_f8;
local_74 = local_f0;
CTraceFilterSimple::CTraceFilterSimple
(local_e0,(IHandleEntity *)0x0,0,(_func_bool_IHandleEntity_ptr_int *)0x0);
(**(code **)(*enginetrace + 0x14))
(enginetrace,(CEffectData *)&local_7c,0x4030,local_e0,local_d0);
if (*(int *)(r_visualizetraces._28_4_ + 0x30) != 0) {
DebugDrawLine(local_d0,(Vector *)&local_c4,0xff,0,0,true,-1.0);
}
if (local_a4 < 1.0) {
local_f4 = local_c4;
local_f0 = local_bc;
local_f8 = local_c0;
}
}
else if (local_98 != 0.0) {
local_f0 = local_98 * 512.0 + local_f0;
}
local_24 = 0;
local_34 = 0;
local_7c = local_f4;
local_70 = 0;
local_78 = local_f8;
local_74 = local_f0;
local_6c = 0;
local_68 = 0;
local_64 = 0;
local_60 = 0;
local_58 = 0;
local_54 = 0;
local_50 = 0;
local_4c = 0;
local_48 = 0;
local_44 = 1.0;
local_38 = 0;
local_40 = 0;
local_3c = 0;
local_30 = 0;
local_2c = 0;
local_28 = 0;
local_23 = 0;
local_5c = 0x3f800000;
lVar2 = (longdouble)(**(code **)(*random_valve + 4))(random_valve,0x3f800000,0x40000000);
local_44 = (float)lVar2;
uVar1 = CBaseEntity::GetWaterType((CBaseEntity *)this);
if ((uVar1 & 0x10) != 0) {
local_4c = local_4c | 1;
}
DispatchEffect("gunshotsplash",(CEffectData *)&local_7c);
return;
}
SourceMod gamedata
paste intoaddons/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.
Signatures + Functions block. The plugin uses
DHookCreateFromConf - DHooks reads return type, this-type,
calling convention, and argument types straight from the gamedata. Less
boilerplate in the plugin, types travel with the gamedata.
Gamedata KeyValues
DHooks plugin example
Type inference is best-effort from the C signature - sanity-check the DHooks types before shipping.