//
// LocalLevelManager::updateLevelRevision from 0x432d74 to 0x432ed6 (354 bytes)
//
// 1 xrefs:
// > LocalLevelManager::dataLoaded @ 0x4334fc
//
// 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
//
void LocalLevelManager::updateLevelRevision(LocalLevelManager *a1)
{
unsigned int v1; // r6
const char *v3; // r8
int v4; // r9
int v5; // r11
cocos2d::CCString *v6; // r0
char *CString; // r0
unsigned int v8; // r5
cocos2d::CCDictionary *v9; // r8
const char *v10; // r6
cocos2d::CCString *v11; // r0
char *v12; // r10
cocos2d::CCNode *v13; // r11
char *v14; // [sp+0h] [bp-24h]
int v15; // [sp+Ch] [bp-18h]
_BYTE v16[4]; // [sp+14h] [bp-10h] BYREF
std::string v17; // [sp+18h] [bp-Ch] BYREF
v1 = 0;
v3 = nullptr;
while ( v1 < cocos2d::CCArray::count(a1->m_localLevels) )
{
v4 = cocos2d::CCArray::objectAtIndex(a1->m_localLevels, v1) + 280;
sub_775C20(v16);
sub_776584((int)&v17, (char *)&unk_939830);
v5 = sub_774DBC(v16, &v17);
sub_774008(&v17);
sub_774008(v16);
if ( !v5 )
{
v6 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat((cocos2d::CCString *)"Unnamed %i", v3);
CString = (char *)cocos2d::CCString::getCString(v6);
sub_776584((int)&v17, CString);
sub_775D40(v4, &v17);
++v3;
sub_774008(&v17);
}
++v1;
}
v8 = 0;
v9 = cocos2d::CCDictionary::create();
while ( v8 < cocos2d::CCArray::count(a1->m_localLevels) )
{
v10 = nullptr;
v14 = (char *)cocos2d::CCArray::objectAtIndex(a1->m_localLevels, v8);
while ( 1 )
{
sub_775C20(&v17);
v11 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat(
(cocos2d::CCString *)"rev_%i_%s",
v10,
v17.m_data.m_data);
v12 = (char *)cocos2d::CCString::getCString(v11);
sub_774008(&v17);
sub_776584((int)&v17, v12);
v15 = cocos2d::CCDictionary::objectForKey(v9, &v17);
sub_774008(&v17);
if ( !v15 )
break;
++v10;
}
v13 = cocos2d::CCNode::create();
sub_776584((int)&v17, v12);
cocos2d::CCDictionary::setObject((int)v9, v13);
++v8;
sub_774008(&v17);
*((_DWORD *)v14 + 90) = v10;
}
}