//
// sub_774B44 from 0x774b44 to 0x774b8e (74 bytes)
//
// 10 xrefs:
// > localStorageInit @ 0x5ad54a
// > cocos2d::CCLabelAtlas::initWithString @ 0x5cb2f4
// > cocos2d::CCFileUtils::addSuffix @ 0x5de7be
// > cocos2d::CCFileUtils::addSuffix @ 0x5de7cc
// > cocos2d::CCFileUtils::getPathForFilename @ 0x5de86a
// > cocos2d::CCSpriteFrameCache::addSpriteFramesWithFile @ 0x5e9ab2
// > cocos2d::CCTMXMapInfo::startElement @ 0x5f92cc
// > cocos2d::CCTMXMapInfo::startElement @ 0x5f92e0
// > cocos2d::CCTMXMapInfo::startElement @ 0x5f96d0
// > cocos2d::CCTMXMapInfo::startElement @ 0x5f96e6
//
// 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
//
unsigned int __fastcall sub_774B44(int *a1, char *a2, unsigned int a3)
{
size_t v6; // r0
int v7; // r5
int v8; // r3
bool v9; // zf
size_t v10; // r6
unsigned int v12; // r3
unsigned __int8 *v13; // r5
int v15; // t1
v6 = strlen(a2);
v7 = *a1;
v8 = *(_DWORD *)(v7 - 12);
v9 = v6 == 0;
if ( v6 )
v9 = v8 == 0;
v10 = v6;
if ( v9 )
return -1;
v12 = v8 - 1;
if ( a3 >= v12 )
a3 = v12;
v13 = (unsigned __int8 *)(v7 + a3);
do
{
v15 = *v13--;
if ( memchr(a2, v15, v10) )
break;
}
while ( a3-- != 0 );
return a3;
}