SurvivorDebugApproach::Update
0x009275e0 · 276 bytes · __thiscall
_ZN21SurvivorDebugApproach6UpdateEP11SurvivorBotf
Decompiled
undefined (3 params)
/* SurvivorDebugApproach::Update(SurvivorBot*, float) */
SurvivorDebugApproach * __thiscall
SurvivorDebugApproach::Update(SurvivorDebugApproach *this,SurvivorBot *param_1,float param_2)
{
float fVar1;
char cVar2;
longdouble lVar3;
cVar2 = (**(code **)(*(int *)((int)param_2 + 0x4028) + 0x118))
((int)param_2 + 0x4028,param_1 + 0x34,0x41c80000);
if (cVar2 != '\0') {
if (*(float *)(param_1 + 0x48) <= 0.0) {
fVar1 = *(float *)(SurvivorBotDebugApproachWaitTime._28_4_ + 0x2c);
lVar3 = (longdouble)CountdownTimer::Now();
if ((float)lVar3 + fVar1 != *(float *)(param_1 + 0x48)) {
(**(code **)(*(int *)(param_1 + 0x40) + 4))(param_1 + 0x40,param_1 + 0x48);
*(float *)(param_1 + 0x48) = (float)lVar3 + fVar1;
}
if (fVar1 != *(float *)(param_1 + 0x44)) {
(**(code **)(*(int *)(param_1 + 0x40) + 4))(param_1 + 0x40,param_1 + 0x44);
*(float *)(param_1 + 0x44) = fVar1;
}
}
else {
lVar3 = (longdouble)CountdownTimer::Now();
if (*(float *)(param_1 + 0x48) <= (float)lVar3) {
*(undefined4 *)this = 3;
*(undefined4 *)(this + 4) = 0;
*(char **)(this + 8) = "Debug move to finished";
return this;
}
}
}
*(undefined4 *)this = 0;
*(undefined4 *)(this + 4) = 0;
*(undefined4 *)(this + 8) = 0;
return this;
}
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.