//
// sub_10060C140 from 0x10060c140 to 0x10060c208 (200 bytes)
//
// 2 xrefs:
// > sub_1005F40F4 @ 0x1005f42d0
// > sub_10060C8E8 @ 0x10060cde8
//
// 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
//
__int64 __fastcall sub_10060C140(__int64 a1, __int64 a2)
{
unsigned int *v3; // x20
__int64 v4; // x0
int v5; // w21
__int64 v6; // x1
if ( !a1 || *(_DWORD *)a1 != 1 )
return 1;
v3 = *(unsigned int **)(a1 + 8);
v4 = sub_1005F3848(a2);
*(_QWORD *)(a1 + 16) = v4;
if ( !v4 )
return 0;
if ( (int)sub_1005DEA4C(v3) > 0 )
{
v5 = 0;
do
{
v6 = sub_1005DEA60((__int64)v3, v5);
if ( !(unsigned int)sub_100602980(*(_QWORD *)(a1 + 16), v6, -1, v5 == 0) )
goto LABEL_11;
}
while ( ++v5 < (int)sub_1005DEA4C(v3) );
}
if ( (sub_1005F3824(*(_QWORD *)(a1 + 16), 0) & 0x80000000) == 0 )
return 1;
LABEL_11:
sub_1005F383C(*(_QWORD *)(a1 + 16));
*(_QWORD *)(a1 + 16) = 0;
return 0;
}