InfectedStaggerAround::Update
0x00a37bb0 · 577 bytes · __cdecl
_ZN21InfectedStaggerAround6UpdateEP8Infectedf
Decompiled
undefined (2 params)
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
/* InfectedStaggerAround::Update(Infected*, float) */
Infected * InfectedStaggerAround::Update(Infected *param_1,float param_2)
{
uint *puVar1;
float fVar2;
int iVar3;
char cVar4;
int iVar5;
bool bVar6;
float fVar7;
CBaseEntity *in_stack_0000000c;
float in_stack_00000010;
undefined4 local_3c;
undefined4 local_38;
undefined4 local_34;
undefined4 local_30;
int local_2c;
undefined4 local_28;
float local_24;
undefined4 local_20;
local_3c = 0;
local_38 = 0;
if (_towlower == 0) {
local_2c = 0;
}
else {
(**(code **)(_towlower + 0x50))
(_towlower,&local_3c,0,0,0,0,
"/data/src/game/server/terror/zombiebot/infected/infectedstaggeraround.cpp",0x29,
&Update(Infected*,float)::tm_fmt,"(%s)%s","NextBot","InfectedStaggerAround::Update");
local_2c = _towlower;
}
iVar3 = _DAT_0105db00;
local_34 = local_3c;
local_30 = local_38;
if ((_DAT_0105d154 != 0) || (DAT_0105d158 == '\0')) {
/* try { // try from 00a37d80 to 00a37de1 has its CatchHandler @ 00a37e1c */
iVar5 = ThreadGetCurrentId();
if (iVar3 == iVar5) {
if ((char *)*_DAT_0105d15c != "InfectedStaggerAround::Update") {
_DAT_0105d15c =
(int *)CVProfNode::GetSubNode((char *)_DAT_0105d15c,0xd24a39,(char *)0x0,0xca8906);
}
puVar1 = (uint *)(_DAT_0105d1e8 + 4 + _DAT_0105d15c[0x1c] * 8);
*puVar1 = *puVar1 | 4;
CVProfNode::EnterScope();
DAT_0105d158 = '\0';
}
}
fVar2 = *(float *)((int)param_2 + 0x38);
fVar7 = in_stack_00000010 * *(float *)(StumbleMaxCurveAccel._28_4_ + 0x2c) +
*(float *)((int)param_2 + 0x34);
*(float *)((int)param_2 + 0x34) = fVar7;
if (fVar2 < fVar7) {
*(float *)((int)param_2 + 0x34) = fVar2;
fVar7 = fVar2;
}
local_28 = *(undefined4 *)(in_stack_0000000c + 0x3a8);
local_24 = fVar7 * in_stack_00000010 + *(float *)(in_stack_0000000c + 0x3ac);
local_20 = *(undefined4 *)(in_stack_0000000c + 0x3b0);
/* try { // try from 00a37ccb to 00a37ccf has its CatchHandler @ 00a37dfb */
CBaseEntity::SetLocalAngles(in_stack_0000000c,(QAngle *)&local_28);
bVar6 = DAT_0105d158 == '\0';
*(undefined4 *)param_1 = 0;
*(undefined4 *)(param_1 + 4) = 0;
*(undefined4 *)(param_1 + 8) = 0;
iVar3 = _DAT_0105db00;
if ((bVar6) || (_DAT_0105d154 != 0)) {
iVar5 = ThreadGetCurrentId();
if (iVar3 == iVar5) {
cVar4 = CVProfNode::ExitScope();
if (cVar4 != '\0') {
_DAT_0105d15c = (int *)_DAT_0105d15c[0x19];
}
DAT_0105d158 = _DAT_0105d15c == (int *)0x105d160;
}
}
if (local_2c != 0) {
(**(code **)(local_2c + 0x54))(local_2c,local_34,local_30,0,0,0);
}
return param_1;
}
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.