//
// CreatorLayer::onSavedLevels from 0x6ca560 to 0x6ca624 (196 bytes)
//
// 3 xrefs:
// > ??> @ 0x71cb8
// > CreatorLayer::init @ 0x6cc560
// > ??> @ 0x122bc20
//
// 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 CreatorLayer::onSavedLevels(CreatorLayer *a1, cocos2d::CCObject *a2)
{
GJSearchObject *v2; // x0
GJSearchObject *v3; // x20
GameManager *v4; // x0
GameManager *v5; // x0
GameManager *v6; // x0
char *v7; // x0
cocos2d::CCDirector *v8; // x19
cocos2d::CCScene *v9; // x0
cocos2d::CCTransitionFade *v10; // x0
GameManager *v11; // x0
if ( GameManager::sharedState()->m_savedSearchType == FavouriteLists )
v2 = (GJSearchObject *)(&qword_60 + 7);
else
v2 = (GJSearchObject *)(&qword_60 + 3);
v3 = (GJSearchObject *)GJSearchObject::create(v2, SavedLevels);
v4 = GameManager::sharedState();
if ( GameManager::getIntGameVariable(v4, "0092") <= 998
&& (v5 = GameManager::sharedState(), GameManager::getIntGameVariable(v5, "0092") <= 0) )
{
LODWORD(v7) = 0;
}
else
{
v6 = GameManager::sharedState();
if ( GameManager::getIntGameVariable(v6, "0092") <= 998 )
{
v11 = GameManager::sharedState();
LODWORD(v7) = GameManager::getIntGameVariable(v11, "0092");
}
else
{
v7 = (char *)&elf_hash_bucket[123] + 3;
}
}
v3->m_folder = (int)v7;
v8 = cocos2d::CCDirector::sharedDirector();
v9 = LevelBrowserLayer::scene(v3);
v10 = cocos2d::CCTransitionFade::create(0.5, v9);
cocos2d::CCDirector::pushScene(v8, v10);
}