//
// sub_10054FAF8 from 0x10054faf8 to 0x10054fb84 (140 bytes)
//
// 2 xrefs:
// > sub_10057C160 @ 0x10057c330
// > sub_10057C160 @ 0x10057c35c
//
// 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_10054FAF8(__int64 *a1, char *__s)
{
size_t v4; // x20
__int64 v5; // x8
_QWORD *v6; // x8
_QWORD *v7; // x21
v4 = strlen(__s);
v5 = *a1;
if ( *((_BYTE *)a1 + 739) && *(_BYTE *)(v5 + 976) )
v6 = (_QWORD *)(v5 + 960);
else
v6 = (_QWORD *)(v5 + 952);
v7 = (_QWORD *)*v6;
if ( !*v6 )
return 0;
while ( !(unsigned int)sub_10057405C(*v7, __s, v4) )
{
v7 = (_QWORD *)v7[1];
if ( !v7 )
return 0;
}
return *v7;
}