//
// sub_9EA78 from 0x9ea78 to 0x9eb44 (204 bytes)
//
// 2 xrefs:
// > sub_9E9F4 @ 0x9ea20
// > sub_9E9F4 @ 0x9ea2c
//
// This function is hookable on this platform (idp: arm, 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 12:14:28 +0000
//
__int64 __fastcall sub_9EA78(__int64 a1, __int64 a2, __int64 a3)
{
__int64 v4; // x0
__int64 result; // x0
unsigned int v7; // w3
__int64 v8; // x8
unsigned int v9; // w0
unsigned int v10; // w2
*(_QWORD *)(a1 + 328) = 0;
*(_QWORD *)(a1 + 360) = 0;
*(_DWORD *)(a1 + 24) = 0;
v4 = *(_QWORD *)(a1 + 368);
*(_DWORD *)(a1 + 40) = 12;
*(_OWORD *)(a1 + 288) = 0u;
*(_OWORD *)(a1 + 304) = 0u;
*(_QWORD *)(a1 + 8) = a1 + 376;
result = (*(__int64 (__fastcall **)(__int64, __int64))(*(_QWORD *)v4 + 24LL))(v4, a1 + 396);
if ( !(_DWORD)result )
{
*(_DWORD *)(a1 + 272) = 0;
v7 = *(_DWORD *)(a3 + 20);
if ( v7 - 1 <= 4 )
{
v8 = *(_QWORD *)(a1 + 8);
*(_DWORD *)(v8 + 8) = v7;
v9 = *(_DWORD *)(v8 + 20);
v10 = *(_QWORD *)(a3 + 12);
*(_QWORD *)(v8 + 12) = *(_QWORD *)(a3 + 12);
sub_5C214(v9, (unsigned int *)(v8 + 24), v10, v7);
*(_DWORD *)(a1 + 24) = 0;
return 0;
}
else
{
return 19;
}
}
return result;
}