CNavArea::InheritAttributes
0x006f9090 · 148 bytes · __thiscall
_ZN8CNavArea17InheritAttributesEPS_S0_
Decompiled
undefined (3 params)
/* CNavArea::InheritAttributes(CNavArea*, CNavArea*) */
void __thiscall CNavArea::InheritAttributes(CNavArea *this,CNavArea *param_1,CNavArea *param_2)
{
int iVar1;
int iVar2;
if (param_1 == (CNavArea *)0x0) {
return;
}
if (param_2 == (CNavArea *)0x0) {
*(uint *)(this + 0x54) = *(uint *)(this + 0x54) | *(uint *)(param_1 + 0x54);
if (*(int *)(this + 0x94) != 0) {
return;
}
}
else {
*(uint *)(this + 0x54) = *(uint *)(param_1 + 0x54) | *(uint *)(param_2 + 0x54);
iVar2 = *(int *)(param_1 + 0x94);
iVar1 = *(int *)(param_2 + 0x94);
if (iVar2 == iVar1) goto LAB_006f90cb;
if (iVar2 == 0) {
*(int *)(this + 0x94) = iVar1;
return;
}
if (iVar1 == 0) goto LAB_006f90cb;
iVar2 = RandomInt(0,100);
if (0x31 < iVar2) {
*(undefined4 *)(this + 0x94) = *(undefined4 *)(param_2 + 0x94);
return;
}
}
iVar2 = *(int *)(param_1 + 0x94);
LAB_006f90cb:
*(int *)(this + 0x94) = iVar2;
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.