//
// sub_10050A0F4 from 0x10050a0f4 to 0x10050a158 (100 bytes)
//
// 3 xrefs:
// > ??> @ 0x100827ac0
// > ??> @ 0x100827ce8
// > ??> @ 0x10082a5a0
//
// 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_10050A0F4(__int64 a1, __int64 a2)
{
__int64 result; // x0
__int64 v5; // x8
_BYTE v6[4]; // [xsp+Ch] [xbp-14h] BYREF
result = (*(__int64 (__fastcall **)(__int64, _BYTE *))(*(_QWORD *)a1 + 152LL))(a1, v6);
if ( !(_DWORD)result )
{
if ( (v6[0] & 0x10) != 0 )
{
result = 0;
if ( a2 )
{
v5 = *(_QWORD *)(a1 + 180);
*(_DWORD *)(a2 + 8) = *(_DWORD *)(a1 + 188);
*(_QWORD *)a2 = v5;
}
}
else
{
return 40;
}
}
return result;
}