MatrixBuildRotationAboutAxis
0x000a2650 · 376 bytes · __cdecl
_Z28MatrixBuildRotationAboutAxisRK6VectorfR11matrix3x4_t
Decompiled
undefined (3 params)
/* MatrixBuildRotationAboutAxis(Vector const&, float, matrix3x4_t&) */
void MatrixBuildRotationAboutAxis(Vector *param_1,float param_2,matrix3x4_t *param_3)
{
float fVar1;
float fVar2;
float fVar3;
float fVar4;
float fVar5;
float local_14;
float local_10;
sincosf(param_2 * 0.017453292,&local_10,&local_14);
fVar2 = *(float *)param_1 * *(float *)param_1;
fVar5 = *(float *)(param_1 + 4) * *(float *)(param_1 + 4);
fVar4 = *(float *)(param_1 + 8) * *(float *)(param_1 + 8);
fVar3 = 1.0 - local_14;
*(float *)param_3 = (1.0 - fVar2) * local_14 + fVar2;
*(float *)(param_3 + 0x10) =
*(float *)(param_1 + 4) * *(float *)param_1 * fVar3 + *(float *)(param_1 + 8) * local_10;
*(float *)(param_3 + 0x20) =
*(float *)param_1 * *(float *)(param_1 + 8) * fVar3 - *(float *)(param_1 + 4) * local_10;
*(float *)(param_3 + 4) =
*(float *)(param_1 + 4) * *(float *)param_1 * fVar3 - *(float *)(param_1 + 8) * local_10;
*(float *)(param_3 + 0x14) = (1.0 - fVar5) * local_14 + fVar5;
*(float *)(param_3 + 0x24) =
*(float *)(param_1 + 8) * *(float *)(param_1 + 4) * fVar3 + *(float *)param_1 * local_10;
*(float *)(param_3 + 8) =
*(float *)param_1 * *(float *)(param_1 + 8) * fVar3 + *(float *)(param_1 + 4) * local_10;
fVar2 = *(float *)(param_1 + 8);
fVar5 = *(float *)param_1;
fVar1 = *(float *)(param_1 + 4);
*(float *)(param_3 + 0x28) = (1.0 - fVar4) * local_14 + fVar4;
*(float *)(param_3 + 0x18) = fVar2 * fVar1 * fVar3 - local_10 * fVar5;
*(undefined4 *)(param_3 + 0xc) = 0;
*(undefined4 *)(param_3 + 0x1c) = 0;
*(undefined4 *)(param_3 + 0x2c) = 0;
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.