//
// LevelBrowserLayer::onSavedMode from 0x1403e8140 to 0x1403e8220 (224 bytes)
//
// 2 xrefs:
// > LevelBrowserLayer::init @ 0x1403e32fe
// > ??> @ 0x140924fd4
//
// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 11:31:44 +0000
//
// Hidden C++ exception states: #wind=1
void __fastcall LevelBrowserLayer::onSavedMode(_QWORD *a1)
{
int v2; // edi
int v3; // ebx
__int64 v4; // rax
__int64 v5; // rax
__int64 v6; // rdx
__int64 v7; // r8
__int64 v8; // r9
struct cocos2d::CCScene *v9; // rax
struct cocos2d::CCScene *v10; // rbx
__int64 v11; // rcx
cocos2d::CCDirector *v12; // rax
void *v13; // [rsp+30h] [rbp+8h]
if ( a1[83] )
{
(*(void (__fastcall **)(_QWORD *, _QWORD))(*a1 + 992LL))(a1, 0);
(*(void (__fastcall **)(_QWORD *, _QWORD))(*a1 + 1008LL))(a1, 0);
v2 = *(_DWORD *)(a1[83] + 320LL);
v3 = 99;
if ( v2 == 99 )
v3 = 103;
v4 = qword_14090BFD0;
if ( !qword_14090BFD0 )
{
v13 = operator new(0x6E8u);
qword_14090BFD0 = GameManager::GameManager((__int64)v13);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFD0 + 72LL))(qword_14090BFD0);
v4 = qword_14090BFD0;
}
*(_DWORD *)(v4 + 1300) = v3;
v5 = GJSearchObject::create_2(v3);
if ( v2 == 99 )
*(_DWORD *)(v5 + 464) = 1;
v9 = (struct cocos2d::CCScene *)LevelBrowserLayer::scene(v5, v6, v7, v8);
v10 = cocos2d::CCTransitionFade::create(0.5, v9);
v12 = (cocos2d::CCDirector *)cocos2d::CCDirector::sharedDirector(v11);
cocos2d::CCDirector::replaceScene(v12, v10);
}
}