//
// sub_BE860 from 0xbe860 to 0xbe8b4 (84 bytes)
//
// 2 xrefs:
// > ??> @ 0x10ee38
// > ??> @ 0x10eed0
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
__int64 __fastcall sub_BE860(__int64 a1, bool *a2)
{
__int16 v2; // w8
unsigned int v3; // w8
__int16 v4; // w8
bool v5; // w8
v2 = atomic_load((unsigned int *)(a1 + 100));
if ( (v2 & 0x100) != 0 )
v3 = 0;
else
v3 = *(_DWORD *)(*(_QWORD *)(a1 + 168) + 69864LL);
v5 = false;
if ( v3 >= *(_DWORD *)(a1 + 724) )
{
v4 = atomic_load((unsigned int *)(a1 + 100));
if ( (v4 & 0x1000) == 0 )
v5 = true;
}
*a2 = v5;
return 0;
}