//
// PlayerObject::updatePlayerGlow from 0x1404fe840 to 0x1404fea21 (481 bytes)
//
// 8 xrefs:
// > PlayerObject::doReversePlayer @ 0x1404f68d0
// > PlayerObject::toggleFlyMode @ 0x1404f89d6
// > PlayerObject::toggleBirdMode @ 0x1404f8c79
// > PlayerObject::resetPlayerIcon @ 0x1404f9690
// > PlayerObject::toggleRobotMode @ 0x1404f9d13
// > PlayerObject::toggleSpiderMode @ 0x1404fa03a
// > PlayerObject::toggleSpiderMode @ 0x1404fa10d
// > ??> @ 0x14092a638
//
// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 11:33:23 +0000
//
__int64 __fastcall PlayerObject::updatePlayerGlow(__int64 a1)
{
char v1; // si
__int64 *v3; // rdi
__int64 v4; // rbx
__int64 *v5; // rdi
__int64 v6; // rbx
__int64 *v7; // rdi
__int64 v8; // rbx
__int64 v9; // rax
__int64 **v10; // rbx
__int64 v11; // rdx
__int64 *v12; // rcx
__int64 *v13; // rdi
__int64 v14; // rax
__int64 v15; // rbx
__int64 v16; // rax
__int64 v17; // rdx
__int64 v18; // rdx
v1 = *(_BYTE *)(a1 + 2097);
v3 = *(__int64 **)(a1 + 1880);
v4 = *v3;
(*(void (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 1856) + 128LL))(*(_QWORD *)(a1 + 1856));
(*(void (__fastcall **)(__int64 *))(v4 + 120))(v3);
v5 = *(__int64 **)(a1 + 1880);
v6 = *v5;
(*(void (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 1856) + 144LL))(*(_QWORD *)(a1 + 1856));
(*(void (__fastcall **)(__int64 *))(v6 + 136))(v5);
v7 = *(__int64 **)(a1 + 1880);
v8 = *v7;
v9 = (*(__int64 (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 1856) + 200LL))(*(_QWORD *)(a1 + 1856));
(*(void (__fastcall **)(__int64 *, __int64))(v8 + 184))(v7, v9);
if ( !v1 && !*(_BYTE *)(a1 + 1842) || (v1 = 1, *(_BYTE *)(a1 + 2501)) || *(_BYTE *)(a1 + 2502) )
{
(*(void (__fastcall **)(_QWORD, _QWORD))(**(_QWORD **)(a1 + 1880) + 336LL))(*(_QWORD *)(a1 + 1880), 0);
v10 = (__int64 **)(a1 + 1888);
}
else
{
(*(void (__fastcall **)(_QWORD, __int64))(**(_QWORD **)(a1 + 1880) + 336LL))(*(_QWORD *)(a1 + 1880), 1);
v10 = (__int64 **)(a1 + 1888);
if ( (*(unsigned __int8 (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 1888) + 344LL))(*(_QWORD *)(a1 + 1888)) )
{
v11 = 1;
goto LABEL_5;
}
}
v11 = 0;
LABEL_5:
(*(void (__fastcall **)(_QWORD, __int64))(**(_QWORD **)(a1 + 1920) + 336LL))(*(_QWORD *)(a1 + 1920), v11);
v12 = *v10;
v13 = *(__int64 **)(a1 + 1920);
v14 = **v10;
v15 = *v13;
v16 = (*(__int64 (__fastcall **)(__int64 *))(v14 + 200))(v12);
(*(void (__fastcall **)(__int64 *, __int64))(v15 + 184))(v13, v16);
if ( v1 && (*(unsigned __int8 (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 2216) + 344LL))(*(_QWORD *)(a1 + 2216)) )
{
LOBYTE(v17) = 1;
(*(void (__fastcall **)(_QWORD, __int64))(**(_QWORD **)(*(_QWORD *)(a1 + 2216) + 768LL) + 336LL))(
*(_QWORD *)(*(_QWORD *)(a1 + 2216) + 768LL),
v17);
}
else
{
(*(void (__fastcall **)(_QWORD, _QWORD))(**(_QWORD **)(*(_QWORD *)(a1 + 2216) + 768LL) + 336LL))(
*(_QWORD *)(*(_QWORD *)(a1 + 2216) + 768LL),
0);
if ( !v1 )
{
LABEL_15:
v18 = 0;
return (*(__int64 (__fastcall **)(_QWORD, __int64))(**(_QWORD **)(*(_QWORD *)(a1 + 2224) + 768LL) + 336LL))(
*(_QWORD *)(*(_QWORD *)(a1 + 2224) + 768LL),
v18);
}
}
if ( !(*(unsigned __int8 (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 2224) + 344LL))(*(_QWORD *)(a1 + 2224)) )
goto LABEL_15;
LOBYTE(v18) = 1;
return (*(__int64 (__fastcall **)(_QWORD, __int64))(**(_QWORD **)(*(_QWORD *)(a1 + 2224) + 768LL) + 336LL))(
*(_QWORD *)(*(_QWORD *)(a1 + 2224) + 768LL),
v18);
}