//
// sub_563BE from 0x563be to 0x5641e (96 bytes)
//
// 0 xrefs:
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
int __fastcall sub_563BE(int a1, int a2, _DWORD *a3)
{
int result; // r0
__int64 v7; // r0
int v8; // r2
int v9; // [sp+4h] [bp-14h] BYREF
result = (*(int (__fastcall **)(int, int *))(*(_DWORD *)a1 + 116))(a1, &v9);
if ( !result )
{
result = 31;
if ( a2 >= 0 && a3 && v9 > a2 )
{
v7 = *(_QWORD *)(a1 + 172);
v8 = 0;
while ( 1 )
{
LODWORD(v7) = *(_DWORD *)v7;
if ( (_DWORD)v7 == HIDWORD(v7) )
break;
if ( !*(_DWORD *)(a1 + 124) || *(_DWORD *)(a1 + 140) == *(unsigned __int16 *)(v7 + 28) )
{
if ( v8 >= a2 )
{
*a3 = v7;
return 0;
}
++v8;
}
}
return 0;
}
}
return result;
}