//
// sub_E4ED0 from 0xe4ed0 to 0xe4fd8 (264 bytes)
//
// 1 xrefs:
// > ??> @ 0x10f270
//
// 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:59 +0000
//
__int64 __fastcall sub_E4ED0(__int64 *a1, int a2)
{
__int64 v4; // x2
_OWORD *v5; // x0
__int64 v6; // x21
__int64 v7; // x1
__int64 result; // x0
__int64 v9; // x8
__int64 v10; // x0
__int64 v11; // x22
__int64 v12; // x21
if ( !a1[9] )
return 67;
if ( !a2 )
return 0;
sub_E5208();
v5 = sub_E2908(*(__int64 *)((char *)&qword_1B0 + (_QWORD)off_114000), 32, v4, 72, 0, 0);
if ( v5 )
{
v6 = (__int64)v5;
sub_5C754(v5);
v7 = a1[9];
a1[8] = v6;
result = sub_5C760(v6, v7, (__int64)a1, a2);
if ( (_DWORD)result )
return result;
sub_E5208();
v10 = sub_E5214(*(_QWORD *)(v9 + 432), (unsigned int)(784 * a2));
a1[131] = v10;
if ( v10 )
{
v11 = 0;
v12 = 0;
while ( v12 < a2 )
{
sub_527DC();
result = (__int64)sub_5C9DC(a1[8], (unsigned int)v12++, a1[131] + v11);
v11 += 784;
if ( (_DWORD)result )
return result;
}
return 0;
}
}
else
{
a1[8] = 0;
}
return 38;
}