//
// sub_1006568EC from 0x1006568ec to 0x1006569e8 (252 bytes)
//
// 1 xrefs:
// > sub_100656870 @ 0x100656890
//
// 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:10:53 +0000
//
__int64 __fastcall sub_1006568EC(__int64 a1, int a2, unsigned __int64 *a3)
{
__int64 result; // x0
__int64 v6; // x20
int v7; // w0
unsigned __int64 v8; // x9
__int64 v9; // x10
char __s2[20]; // [xsp+4h] [xbp-3Ch] BYREF
result = 0;
if ( a1 && a2 <= 19 && *a3 != 28 )
{
v6 = a2;
__memcpy_chk(__s2, a1, a2, 20);
__s2[v6] = 0;
v7 = sub_1006E3684(__s2);
if ( !v7 )
{
v7 = sub_1006B13D0(__s2);
if ( !v7 )
{
v7 = sub_1006B14D4(__s2);
if ( !v7 )
return 0;
}
}
v8 = *a3;
if ( *a3 )
{
v9 = 0;
while ( *((_DWORD *)a3 + v9 + 2) != v7 )
{
if ( ++v9 >= v8 )
goto LABEL_13;
}
return 0;
}
v8 = 0;
LABEL_13:
*a3 = v8 + 1;
*((_DWORD *)a3 + v8 + 2) = v7;
return 1;
}
return result;
}