TransformIntoNeighbor
0x000d0ea0 · 168 bytes · __cdecl
_Z21TransformIntoNeighborP16CDispUtilsHelperiRK10CVertIndexRS1_
Decompiled
undefined (4 params)
/* TransformIntoNeighbor(CDispUtilsHelper*, int, CVertIndex const&, CVertIndex&) */
undefined4
TransformIntoNeighbor(CDispUtilsHelper *param_1,int param_2,CVertIndex *param_3,CVertIndex *param_4)
{
int iVar1;
undefined4 uVar2;
if (param_2 == -1) {
iVar1 = (*(code *)**(undefined4 **)param_1)(param_1);
if (*(short *)param_3 == 0) {
param_2 = 0;
}
else {
iVar1 = 1 << ((byte)*(undefined4 *)(iVar1 + 0x1c) & 0x1f);
if (iVar1 == *(short *)(param_3 + 2)) {
param_2 = 1;
}
else if (iVar1 == *(short *)param_3) {
param_2 = 2;
}
else if (*(short *)(param_3 + 2) == 0) {
param_2 = 3;
}
}
}
iVar1 = GetSubNeighborIndex(param_1,param_2,param_3);
if (iVar1 == -1) {
uVar2 = 0;
}
else {
uVar2 = TransformIntoSubNeighbor(param_1,param_2,iVar1,param_3,param_4);
}
return uVar2;
}
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.