//
// sub_1005886FC from 0x1005886fc to 0x100588780 (132 bytes)
//
// 1 xrefs:
// > sub_10058C338 @ 0x10058eb6c
//
// 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 11:08:33 +0000
//
__int64 __fastcall sub_1005886FC(__int64 a1)
{
int v2; // w8
__int64 v3; // x9
__int64 v4; // x10
int v5; // w10
sub_1005D8DAC();
v2 = *(_DWORD *)(a1 + 2292);
v3 = *(int *)(a1 + 3068);
while ( 1 )
{
v4 = *(unsigned __int8 *)(a1 + v3 + 656);
if ( v2 > (int)v4 )
break;
v5 = v3 + 1;
*(_DWORD *)(a1 + 3068) = v3 + 1;
if ( (int)v3 <= 253 )
{
++v3;
if ( v5 < *(_DWORD *)(a1 + 2284) )
continue;
}
*(_WORD *)(a1 + 3048) = 256;
return 19;
}
*(_QWORD *)(a1 + 17440) = *(_QWORD *)(*(_QWORD *)(a1 + 632) + 16 * v4 + 8);
sub_100589F68(a1);
return 0;
}