//
// sub_774BC4 from 0x774bc4 to 0x774c02 (62 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_774BC4(_DWORD *a1, const void **a2, unsigned int a3)
{
unsigned int v3; // r4
const void *v4; // r6
unsigned int v5; // r7
size_t v6; // r8
unsigned __int8 *v7; // r5
int v8; // t1
v3 = a3;
v4 = *a2;
v5 = *(_DWORD *)(*a1 - 12);
v6 = *((_DWORD *)*a2 - 3);
if ( a3 >= v5 )
return -1;
v7 = (unsigned __int8 *)(*a1 + a3);
while ( 1 )
{
v8 = *v7++;
if ( !memchr(v4, v8, v6) )
break;
if ( ++v3 >= v5 )
return -1;
}
return v3;
}