//
// sub_10044C9AC from 0x10044c9ac to 0x10044ca2c (128 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
//
__int64 __fastcall sub_10044C9AC(__int64 a1)
{
__int64 v2; // x19
int v3; // w22
__int64 v4; // x0
__int64 v5; // x21
v2 = *(_QWORD *)(a1 + 32);
sub_1004B5C70(v2);
if ( *(int *)(a1 + 60) < 1 )
{
v5 = 0;
}
else
{
v3 = 0;
while ( 1 )
{
v4 = sub_1004B5DD4(*(_QWORD *)(a1 + 48));
if ( (_DWORD)v4 )
break;
if ( ++v3 >= *(_DWORD *)(a1 + 60) )
{
v5 = 0;
*(_DWORD *)(a1 + 60) = 0;
goto LABEL_8;
}
}
v5 = v4;
}
LABEL_8:
sub_1004B5CA0(v2);
return v5;
}