//
// sub_1005112D0 from 0x1005112d0 to 0x100511348 (120 bytes)
//
// 1 xrefs:
// > ??> @ 0x1008588f0
//
// 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_1005112D0(__int64 *a1, int a2, int a3)
{
__int64 result; // x0
__int64 v5; // x20
int *v6; // x1
int *v7; // [xsp+8h] [xbp-18h] BYREF
if ( a2 )
return 0;
v5 = *a1;
result = sub_10043E710(*(_QWORD *)(*a1 + 168), &v7, 24, 1);
if ( !(_DWORD)result )
{
*(_BYTE *)v7 = 9;
v6 = v7;
*((_QWORD *)v7 + 1) = v5;
v6[4] = a3;
result = sub_10043E7B4(*(_QWORD *)(v5 + 168), (__int64)v6, 1);
if ( !(_DWORD)result )
*(_DWORD *)(v5 + 552) = a3;
}
return result;
}