//
// sub_9989F0 from 0x9989f0 to 0x998a28 (56 bytes)
//
// 1 xrefs:
// > sub_997FF4 @ 0x99807e
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// 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:06:42 +0000
//
int __fastcall sub_9989F0(int *a1, int *a2)
{
int v3; // r3
int *v4; // r1
int v5; // lr
int v6; // t1
int result; // r0
int *v8; // r2
int v9; // r4
int v10; // t1
v3 = *a1;
if ( *a1 )
{
v6 = *a2;
v4 = a2 + 1;
v5 = v6;
result = 0;
while ( 1 )
{
v8 = v4;
v9 = v5;
if ( !v5 )
break;
while ( v9 != v3 )
{
v10 = *v8++;
v9 = v10;
if ( !v10 )
return result;
}
v3 = a1[++result];
if ( !v3 )
return result;
}
}
return 0;
}