CCoreDispInfo::CalcTriSurfBoundingBoxes
0x000beb40 · 210 bytes · __thiscall
_ZN13CCoreDispInfo24CalcTriSurfBoundingBoxesEiPA3_i
Decompiled
undefined (3 params)
/* CCoreDispInfo::CalcTriSurfBoundingBoxes(int, int (*) [3]) */
void __thiscall
CCoreDispInfo::CalcTriSurfBoundingBoxes(CCoreDispInfo *this,int param_1,int *param_2)
{
int *piVar1;
float *pfVar2;
float *pfVar3;
float fVar4;
float fVar5;
int iVar6;
int iVar7;
int iVar8;
float fVar9;
float fVar10;
float fVar11;
float fVar12;
float fVar13;
float fVar14;
float local_14;
iVar8 = 0;
do {
iVar6 = *(int *)(this + 4) + param_1 * 0x200;
pfVar2 = (float *)(iVar6 + 0x40 + iVar8 * 0x18);
pfVar3 = (float *)(iVar6 + 0x4c + iVar8 * 0x18);
fVar14 = *pfVar2;
fVar13 = pfVar2[1];
fVar10 = pfVar2[2];
fVar12 = *pfVar3;
fVar11 = pfVar3[1];
iVar6 = 0;
local_14 = pfVar3[2];
do {
piVar1 = param_2 + iVar6;
iVar6 = iVar6 + 1;
iVar7 = *piVar1 * 0x90 + *(int *)(this + 0x1b8);
fVar9 = *(float *)(iVar7 + 0x30);
fVar4 = *(float *)(iVar7 + 0x28);
if (fVar9 <= fVar10) {
fVar10 = fVar9;
}
fVar5 = *(float *)(iVar7 + 0x2c);
if (fVar9 <= local_14) {
fVar9 = local_14;
}
if (fVar4 <= fVar14) {
fVar14 = fVar4;
}
if (fVar5 <= fVar13) {
fVar13 = fVar5;
}
if (fVar12 <= fVar4) {
fVar12 = fVar4;
}
if (fVar11 <= fVar5) {
fVar11 = fVar5;
}
local_14 = fVar9;
} while (iVar6 != 3);
iVar8 = iVar8 + 1;
param_2 = param_2 + 3;
*pfVar2 = fVar14;
pfVar2[1] = fVar13;
pfVar2[2] = fVar10;
*pfVar3 = fVar12;
pfVar3[1] = fVar11;
pfVar3[2] = fVar9;
} while (iVar8 != 8);
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.