CPropDoorRotating::DoorCanClose
0x007fba80 · 395 bytes · __cdecl
_ZN17CPropDoorRotating12DoorCanCloseEb
Decompiled
undefined (1 param)
/* CPropDoorRotating::DoorCanClose(bool) */
undefined4 CPropDoorRotating::DoorCanClose(bool param_1)
{
uint uVar1;
int iVar2;
char cVar3;
CPropDoorRotating *pCVar4;
undefined4 uVar5;
bool bVar6;
undefined *puVar7;
int iVar8;
undefined3 in_stack_00000005;
uVar1 = *(uint *)(_param_1 + 0x1668);
if ((((uVar1 != 0xffffffff) &&
(puVar7 = g_pEntityList + (uVar1 & 0xfff) * 0x10, puVar7 != (undefined *)0xfffffffc)) &&
(*(uint *)(puVar7 + 8) == uVar1 >> 0xc)) && (*(int **)(puVar7 + 4) != (int *)0x0)) {
/* WARNING: Could not recover jumptable at 0x007fbbbd. Too many branches */
/* WARNING: Treating indirect jump as call */
uVar5 = (**(code **)(**(int **)(puVar7 + 4) + 0x48c))();
return uVar5;
}
iVar2 = *(int *)(_param_1 + 0x15e8);
iVar8 = 0;
if (0 < iVar2) {
do {
uVar1 = *(uint *)(*(int *)(_param_1 + 0x15dc) + iVar8 * 4);
if (((uVar1 != 0xffffffff) &&
(puVar7 = g_pEntityList + (uVar1 & 0xfff) * 0x10, puVar7 != (undefined *)0xfffffffc)) &&
((*(uint *)(puVar7 + 8) == uVar1 >> 0xc &&
((*(int *)(puVar7 + 4) != 0 &&
(pCVar4 = (CPropDoorRotating *)
__dynamic_cast(*(int *)(puVar7 + 4),&CBasePropDoor::typeinfo,&typeinfo,0),
pCVar4 != (CPropDoorRotating *)0x0)))))) {
if ((*(float *)(pCVar4 + 0x1774) == *(float *)(pCVar4 + 0x178c)) &&
(*(float *)(pCVar4 + 0x1778) == *(float *)(pCVar4 + 0x1790))) {
bVar6 = *(float *)(pCVar4 + 0x177c) != *(float *)(pCVar4 + 0x1794);
}
else {
bVar6 = true;
}
cVar3 = CheckDoorClear(pCVar4,bVar6);
if (cVar3 == '\0') {
return 0;
}
}
iVar8 = iVar8 + 1;
} while (iVar8 != iVar2);
}
uVar5 = CheckDoorClear();
return uVar5;
}
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.