CPhysicsCannister::CalcLocalThrust
0x00787d50 · 196 bytes · __cdecl
_ZN17CPhysicsCannister15CalcLocalThrustERK6Vector
Decompiled
undefined (1 param)
/* CPhysicsCannister::CalcLocalThrust(Vector const&) */
Vector * CPhysicsCannister::CalcLocalThrust(Vector *param_1)
{
float fVar1;
float fVar2;
code *pcVar3;
CBaseAnimating *in_stack_00000008;
float *in_stack_0000000c;
matrix3x4_t local_4c [60];
pcVar3 = *(code **)(*(int *)in_stack_00000008 + 0x370);
CBaseAnimating::LookupAttachment(in_stack_00000008,"nozzle");
(*pcVar3)();
MatrixGetColumn(local_4c,2,param_1);
MatrixGetColumn(local_4c,3,(Vector *)(in_stack_00000008 + 0x1a40));
fVar1 = in_stack_0000000c[2];
fVar2 = *in_stack_0000000c;
*(float *)(param_1 + 4) = *(float *)(param_1 + 4) * -5.0 + in_stack_0000000c[1];
*(float *)(param_1 + 8) = *(float *)(param_1 + 8) * -5.0 + fVar1;
*(float *)param_1 = *(float *)param_1 * -5.0 + fVar2;
VectorNormalize(param_1);
return param_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.