//
// LevelPage::playStep3 from 0x14031dcf0 to 0x14031dde6 (246 bytes)
//
// 2 xrefs:
// > LevelPage::playStep2 @ 0x14031dca5
// > ??> @ 0x1406d4b5c
//
// 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
//
// Hidden C++ exception states: #wind=2
void LevelPage::playStep3(LevelPage *a1)
{
__int64 v2; // rax
unsigned int v3; // ebx
LocalLevelManager *v4; // rax
__int64 MainLevelString; // rax
__int64 v6; // rbx
std::string *p_m_levelString; // rcx
void *v8; // rdx
struct cocos2d::CCScene *v9; // rax
struct cocos2d::CCTransitionFade *v10; // rbx
__int64 v11; // rcx
cocos2d::CCDirector *v12; // rax
_BYTE v13[40]; // [rsp+20h] [rbp-28h] BYREF
void *v14; // [rsp+50h] [rbp+8h]
v2 = qword_1406C2ED8;
if ( !qword_1406C2ED8 )
{
v14 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00((__int64)v14);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
v2 = qword_1406C2ED8;
}
*(_DWORD *)(v2 + 700) = 9;
v3 = a1->m_level->m_levelID.random - a1->m_level->m_levelID.seed;
v4 = LocalLevelManager::sharedState();
MainLevelString = LocalLevelManager::getMainLevelString(v4, v13, v3);
v6 = MainLevelString;
p_m_levelString = &a1->m_level->m_levelString;
if ( p_m_levelString != (std::string *)MainLevelString )
{
v8 = (void *)MainLevelString;
if ( *(_QWORD *)(MainLevelString + 24) > 0xFu )
v8 = *(void **)MainLevelString;
sub_14003CCE0((void **)p_m_levelString, v8, *(_QWORD *)(MainLevelString + 16));
}
sub_14003A830(v6);
v9 = PlayLayer::scene(a1->m_level, 0, 0);
v10 = cocos2d::CCTransitionFade::create(0.5, v9);
v12 = (cocos2d::CCDirector *)cocos2d::CCDirector::sharedDirector(v11);
cocos2d::CCDirector::replaceScene(v12, v10);
}