CFuncLadder::DrawDebugGeometryOverlays
0x0044f990 · 1096 bytes · __thiscall
_ZN11CFuncLadder25DrawDebugGeometryOverlaysEv
Decompiled
undefined (1 param)
/* CFuncLadder::DrawDebugGeometryOverlays() */
void __thiscall CFuncLadder::DrawDebugGeometryOverlays(CFuncLadder *this)
{
uint uVar1;
CBaseEntity *this_00;
int iVar2;
undefined *puVar3;
int iVar4;
float local_10c;
float local_108;
float local_104;
float local_100;
float local_fc;
float local_f8;
Vector local_f4 [12];
Vector local_e8 [12];
undefined4 local_dc;
undefined4 local_d8;
undefined4 local_d4;
float local_cc;
float local_c8;
float local_c4;
undefined4 local_bc;
undefined4 local_b8;
undefined4 local_b4;
float local_ac;
float local_a8;
float local_a4;
float local_9c;
float local_98;
float local_94;
undefined4 local_8c;
undefined1 local_88;
undefined1 local_87;
Vector local_70 [12];
Vector local_64 [84];
CBaseEntity::DrawDebugGeometryOverlays((CBaseEntity *)this);
iVar2 = (**(code **)(*g_pGameRules + 0x7c))(g_pGameRules);
local_10c = *(float *)(iVar2 + 0xc);
local_108 = *(float *)(iVar2 + 0x10);
local_104 = *(float *)(iVar2 + 0x14);
iVar2 = (**(code **)(*g_pGameRules + 0x7c))(g_pGameRules);
local_100 = *(float *)(iVar2 + 0x18);
local_fc = *(float *)(iVar2 + 0x1c);
local_f8 = *(float *)(iVar2 + 0x20);
GetTopPosition(this,local_f4);
GetBottomPosition(this,local_e8);
NDebugOverlay::Box(local_f4,(Vector *)&local_10c,(Vector *)&local_100,0xff,0,0,0x7f,0.0);
NDebugOverlay::Box(local_e8,(Vector *)&local_10c,(Vector *)&local_100,0,0,0xff,0x7f,0.0);
NDebugOverlay::EntityBounds((CBaseEntity *)this,200,0xb4,0x3f,0x3f,0.0);
local_bc = 0;
local_87 = 0;
local_b8 = 0;
local_b4 = 0;
local_8c = 0;
local_9c = (local_100 - local_10c) * 0.5;
local_98 = (local_fc - local_108) * 0.5;
local_94 = (local_f8 - local_104) * 0.5;
local_ac = (local_100 + local_10c) * 0.5;
local_a4 = (local_f8 + local_104) * 0.5;
local_a8 = (local_fc + local_108) * 0.5;
local_c4 = *(float *)(this + 0x474) + local_a4;
local_cc = *(float *)(this + 0x46c) + local_ac;
local_ac = -local_ac;
local_c8 = *(float *)(this + 0x470) + local_a8;
local_a8 = -local_a8;
local_88 = local_98 * local_98 + local_9c * local_9c + local_94 * local_94 < 1e-06;
local_a4 = -local_a4;
CTraceFilterSimple::CTraceFilterSimple
((CTraceFilterSimple *)&local_dc,(IHandleEntity *)0x0,8,
(_func_bool_IHandleEntity_ptr_int *)0x0);
(**(code **)(*enginetrace + 0x14))
(enginetrace,&local_cc,0x1400b,(CTraceFilterSimple *)&local_dc,local_70);
if (*(int *)(r_visualizetraces._28_4_ + 0x30) != 0) {
DebugDrawLine(local_70,local_64,0xff,0xff,0,true,-1.0);
}
iVar2 = *(int *)(this + 0x458);
iVar4 = 0;
if (0 < iVar2) {
do {
while ((((uVar1 = *(uint *)(*(int *)(this + 0x44c) + iVar4 * 4), uVar1 == 0xffffffff ||
(puVar3 = g_pEntityList + (uVar1 & 0xfff) * 0x10, puVar3 == (undefined *)0xfffffffc))
|| (*(uint *)(puVar3 + 8) != uVar1 >> 0xc)) ||
(this_00 = *(CBaseEntity **)(puVar3 + 4), this_00 == (CBaseEntity *)0x0))) {
iVar4 = iVar4 + 1;
if (iVar4 == iVar2) {
return;
}
}
local_cc = 16.0;
local_c8 = 16.0;
local_c4 = 8.0;
local_dc = 0xc1800000;
local_d8 = 0xc1800000;
local_d4 = 0;
if (((byte)this_00[0x14d] & 8) != 0) {
CBaseEntity::CalcAbsolutePosition(this_00);
}
iVar4 = iVar4 + 1;
NDebugOverlay::Box((Vector *)(this_00 + 0x2e0),(Vector *)&local_dc,(Vector *)&local_cc,0x96,0,
0,0x3f,0.0);
} while (iVar4 != 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.