//
// sub_1004D8BD0 from 0x1004d8bd0 to 0x1004d8c48 (120 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_1004D8BD0(unsigned __int8 *a1, int a2)
{
unsigned __int8 *v2; // x20
int v3; // w8
unsigned __int8 *v4; // x19
__int64 result; // x0
v2 = &a1[a2];
if ( a2 )
{
do
{
v3 = *a1;
if ( v3 == 61 )
break;
if ( (unsigned int)(v3 - 126) < 0xFFFFFFA2 )
return 0;
++a1;
}
while ( a1 < v2 );
}
if ( a1 == v2 )
return 0;
v4 = a1 + 1;
while ( v4 < v2 )
{
result = sub_1004D89D0(v4);
v4 += (unsigned int)result;
if ( !(_DWORD)result )
return result;
}
return v4 == v2;
}