AdjustTransformForScale
0x005e09b0 · 312 bytes · __cdecl
_Z23AdjustTransformForScaleR11matrix3x4_tRK6Vectorf
Decompiled
undefined (3 params)
/* AdjustTransformForScale(matrix3x4_t&, Vector const&, float) */
void AdjustTransformForScale(matrix3x4_t *param_1,Vector *param_2,float param_3)
{
float local_28;
float local_24;
float local_20;
if ((param_3 <= 1.0000001) && (0.9999999 <= param_3)) {
return;
}
MatrixGetColumn(param_1,3,(Vector *)&local_28);
local_24 = (local_24 - *(float *)(param_2 + 4)) * param_3 + *(float *)(param_2 + 4);
local_20 = (local_20 - *(float *)(param_2 + 8)) * param_3 + *(float *)(param_2 + 8);
local_28 = (local_28 - *(float *)param_2) * param_3 + *(float *)param_2;
MatrixSetColumn((Vector *)&local_28,3,param_1);
*(float *)param_1 = *(float *)param_1 * param_3;
*(float *)(param_1 + 4) = *(float *)(param_1 + 4) * param_3;
*(float *)(param_1 + 8) = *(float *)(param_1 + 8) * param_3;
*(float *)(param_1 + 0x10) = *(float *)(param_1 + 0x10) * param_3;
*(float *)(param_1 + 0x14) = *(float *)(param_1 + 0x14) * param_3;
*(float *)(param_1 + 0x18) = *(float *)(param_1 + 0x18) * param_3;
*(float *)(param_1 + 0x20) = *(float *)(param_1 + 0x20) * param_3;
*(float *)(param_1 + 0x24) = *(float *)(param_1 + 0x24) * param_3;
*(float *)(param_1 + 0x28) = param_3 * *(float *)(param_1 + 0x28);
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.