CVoxelHash::EnumerateElementsAtPoint
0x001dc6f0 · 262 bytes · __thiscall
_ZN10CVoxelHash24EnumerateElementsAtPointEi7Voxel_tRK6VectorP20IPartitionEnumerator
Decompiled
undefined (5 params)
/* CVoxelHash::EnumerateElementsAtPoint(int, Voxel_t, Vector const&, IPartitionEnumerator*) */
undefined4 __thiscall
CVoxelHash::EnumerateElementsAtPoint
(CVoxelHash *this,ushort param_1,uint param_3,Vector *param_4,undefined4 *param_5)
{
ushort uVar1;
ushort *puVar2;
char cVar3;
int iVar4;
uint uVar5;
uint *puVar6;
Vector *pVVar7;
uVar5 = (((int)param_3 >> 0x10 & 0xffU) +
((param_3 >> 8 & 0xff) + ((param_3 & 0xff) + 0xaaaaaaaa) * 0x21) * 0x21) * 0x21 +
(param_3 >> 0x18);
puVar6 = *(uint **)(this + (((int)uVar5 >> 0x10 ^ uVar5) & 0x1ff) * 8 + 0xc);
while( true ) {
if (puVar6 == (uint *)0x0) {
return 1;
}
if (param_3 == *puVar6) break;
puVar6 = (uint *)puVar6[3];
if (*(uint **)(this + (((int)uVar5 >> 0x10 ^ uVar5) & 0x1ff) * 8 + 0xc) == puVar6) {
return 1;
}
}
if (puVar6 == (uint *)&DAT_ffffffff) {
return 1;
}
puVar2 = (ushort *)puVar6[1];
do {
if (puVar2 == (ushort *)0x0) {
return 1;
}
uVar1 = *puVar2;
puVar2 = *(ushort **)(puVar2 + 4);
} while ((((uVar1 == 0xffff) ||
(pVVar7 = (Vector *)
((uint)uVar1 * 0x34 +
*(int *)(*(int *)(*(int *)(this + 0x1048) + 0xbc) + 0x10)),
(param_1 & *(ushort *)(pVVar7 + 0x1c)) == 0)) || (((byte)pVVar7[0x1e] & 1) != 0)) ||
((cVar3 = IsPointInBox(param_4,pVVar7,pVVar7 + 0xc), cVar3 == '\0' ||
(iVar4 = (**(code **)*param_5)(param_5,*(undefined4 *)(pVVar7 + 0x18)), iVar4 != 1))));
return 0;
}
SourceMod gamedata
paste intoaddons/sourcemod/gamedata/<your_plugin>.txt
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.
Type inference is best-effort from the C signature - sanity-check the DHooks types before shipping.