CWeaponCSBase::PhysicsSplash
0x0043f480 · 383 bytes · __cdecl
_ZN13CWeaponCSBase13PhysicsSplashERK6VectorS2_ff
Decompiled
undefined (4 params)
/* CWeaponCSBase::PhysicsSplash(Vector const&, Vector const&, float, float) */
undefined4 CWeaponCSBase::PhysicsSplash(Vector *param_1,Vector *param_2,float param_3,float param_4)
{
int iVar1;
uint uVar2;
longdouble lVar3;
float fVar4;
float fVar5;
undefined4 local_6c;
undefined4 local_68;
undefined4 local_64;
undefined4 local_60;
undefined4 local_5c;
undefined4 local_58;
undefined4 local_54;
undefined4 local_50;
undefined4 local_4c;
undefined4 local_48;
undefined4 local_44;
undefined4 local_40;
uint local_3c;
undefined4 local_38;
float local_34;
undefined4 local_30;
undefined4 local_2c;
undefined4 local_28;
undefined2 local_24;
undefined4 local_20;
undefined4 local_1c;
undefined4 local_18;
undefined1 local_14;
undefined1 local_13;
if (param_4 <= 20.0) {
return 0;
}
iVar1 = CBaseCombatWeapon::GetWpnData((CBaseCombatWeapon *)param_1);
fVar5 = 6.0;
if (*(int *)(iVar1 + 0x894) == 0) {
fVar5 = 4.0;
}
fVar4 = param_4 * 0.0025;
local_60 = 0;
local_5c = 0;
local_58 = 0;
local_48 = 0;
if (1.0 <= fVar4) {
fVar4 = 1.0;
}
local_44 = 0;
local_40 = 0;
local_30 = 0;
local_2c = 0;
if (fVar4 <= 0.0) {
fVar4 = 0.0;
}
local_6c = *(undefined4 *)param_2;
local_24 = 0;
local_68 = *(undefined4 *)(param_2 + 4);
local_34 = 1.0;
local_64 = *(undefined4 *)(param_2 + 8);
local_3c = 0;
local_54 = *(undefined4 *)param_3;
fVar5 = fVar4 * 3.0 + fVar5;
local_38 = 0;
local_50 = *(undefined4 *)((int)param_3 + 4);
local_28 = 0;
local_4c = *(undefined4 *)((int)param_3 + 8);
local_20 = 0;
local_1c = 0;
local_18 = 0;
local_14 = 0;
local_13 = 0;
lVar3 = (longdouble)(**(code **)(*random_valve + 4))(random_valve,fVar5,fVar5 + 1.0);
local_34 = (float)lVar3;
uVar2 = CBaseEntity::GetWaterType((CBaseEntity *)param_1);
if ((uVar2 & 0x10) != 0) {
local_3c = local_3c | 1;
}
DispatchEffect("gunshotsplash",(CEffectData *)&local_6c);
return 1;
}
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.