CLogicLineToEntity::Think
0x006e8db0 · 567 bytes · __thiscall
_ZN18CLogicLineToEntity5ThinkEv
Decompiled
undefined (1 param)
/* CLogicLineToEntity::Think() */
void __thiscall CLogicLineToEntity::Think(CLogicLineToEntity *this)
{
float fVar1;
float fVar2;
float fVar3;
uint uVar4;
CBaseEntity *this_00;
undefined4 uVar5;
undefined *puVar6;
CBaseEntity *this_01;
float fVar7;
undefined4 local_30;
undefined4 local_2c;
undefined4 local_28;
undefined4 local_24;
undefined4 local_20;
uVar5 = vec3_origin;
this_01 = (CBaseEntity *)0x0;
uVar4 = *(uint *)(this + 0x460);
if (((uVar4 != 0xffffffff) &&
(puVar6 = g_pEntityList + (uVar4 & 0xfff) * 0x10, puVar6 != (undefined *)0xfffffffc)) &&
(*(uint *)(puVar6 + 8) == uVar4 >> 0xc)) {
this_01 = *(CBaseEntity **)(puVar6 + 4);
}
uVar4 = *(uint *)(this + 0x45c);
if (((((uVar4 == 0xffffffff) ||
(puVar6 = g_pEntityList + (uVar4 & 0xfff) * 0x10, puVar6 == (undefined *)0xfffffffc)) ||
((*(uint *)(puVar6 + 8) != uVar4 >> 0xc ||
((this_00 = *(CBaseEntity **)(puVar6 + 4), this_01 == (CBaseEntity *)0x0 ||
(this_00 == (CBaseEntity *)0x0)))))) || (*(int *)(this_01 + 0x30) == 0)) ||
(*(int *)(this_00 + 0x30) == 0)) {
local_20 = 3;
*(undefined4 *)(this + 0x450) = 3;
*(undefined4 *)(this + 0x440) = uVar5;
local_30 = *(undefined4 *)(this + 0x440);
*(undefined4 *)(this + 0x444) = DAT_01053d4c;
*(undefined4 *)(this + 0x448) = DAT_01053d50;
local_2c = *(undefined4 *)(this + 0x444);
local_28 = *(undefined4 *)(this + 0x448);
local_24 = *(undefined4 *)(this + 0x44c);
CBaseEntityOutput::FireOutput((CBaseEntityOutput *)(this + 0x440),&local_30,this,this,0);
fVar7 = 10.0;
}
else {
if (((byte)this_00[0x14d] & 8) != 0) {
CBaseEntity::CalcAbsolutePosition(this_00);
}
if (((byte)this_01[0x14d] & 8) != 0) {
CBaseEntity::CalcAbsolutePosition(this_01);
}
fVar7 = *(float *)(this_01 + 0x2e4);
fVar1 = *(float *)(this_01 + 0x2e8);
fVar2 = *(float *)(this_00 + 0x2e4);
fVar3 = *(float *)(this_00 + 0x2e8);
*(float *)(this + 0x440) = *(float *)(this_01 + 0x2e0) - *(float *)(this_00 + 0x2e0);
local_30 = *(undefined4 *)(this + 0x440);
local_20 = 3;
*(float *)(this + 0x444) = fVar7 - fVar2;
*(float *)(this + 0x448) = fVar1 - fVar3;
*(undefined4 *)(this + 0x450) = 3;
local_2c = *(undefined4 *)(this + 0x444);
local_28 = *(undefined4 *)(this + 0x448);
local_24 = *(undefined4 *)(this + 0x44c);
CBaseEntityOutput::FireOutput((CBaseEntityOutput *)(this + 0x440),&local_30,this,this,0);
fVar7 = 0.01;
}
CBaseEntity::SetNextThink((CBaseEntity *)this,fVar7 + *(float *)(gpGlobals + 0xc),(char *)0x0);
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.