//
// sub_9885C2 from 0x9885c2 to 0x9885ea (40 bytes)
//
// 2 xrefs:
// > sub_986930 @ 0x9870a6
// > sub_986930 @ 0x987334
//
// 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:22 +0000
//
int __fastcall sub_9885C2(int result, unsigned __int8 *a2)
{
unsigned __int64 v2; // kr00_8
unsigned int v3; // r12
if ( (unsigned __int8 *)result != a2 )
{
v2 = *(_QWORD *)(a2 + 4);
v3 = *a2;
if ( (v3 & 1) == 0 )
v2 = __PAIR64__((unsigned int)(a2 + 1), v3 >> 1);
return sub_98987A(result, HIDWORD(v2), v2);
}
return result;
}