//
// sub_1005E7DE0 from 0x1005e7de0 to 0x1005e7e64 (132 bytes)
//
// 3 xrefs:
// > ??> @ 0x10083d200
// > ??> @ 0x10083d258
// > ??> @ 0x10083d2b0
//
// 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_1005E7DE0(__int64 a1, __int64 a2, unsigned __int64 a3)
{
__int64 v5; // x21
if ( a2 | a3 )
{
v5 = *(_QWORD *)(a1 + 120);
if ( a2 )
{
if ( *(_DWORD *)(a1 + 16) )
sub_10059ADB0();
else
sub_10059ADB4();
if ( !a3 )
{
*(_QWORD *)(v5 + 248) = 0;
return 1;
}
}
else if ( !a3 )
{
return 1;
}
*(_QWORD *)(a1 + 40) = *(_QWORD *)a3;
*(_QWORD *)(v5 + 248) = a1 + 40;
}
return 1;
}