{"type": "func", "start": 5371649904, "end": 5371650128, "name": "LevelBrowserLayer::onSavedMode", "pseudocode": "// \n// LevelBrowserLayer::onSavedMode from 0x1402cdf70 to 0x1402ce050 (224 bytes)\n// \n// 2 xrefs:\n// > LevelBrowserLayer::init @ 0x1402ca15b\n// > <???> @ 0x1406d2d80\n// \n// This function is hookable on this platform!\n// \n// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings\n// \n\n// Hidden C++ exception states: #wind=1\nvoid LevelBrowserLayer::onSavedMode(LevelBrowserLayer *a1, cocos2d::CCObject *a2)\n{\n  SearchType m_searchType; // edi\n  SearchType v4; // ebx\n  __int64 v5; // rax\n  GJSearchObject *v6; // rax\n  struct cocos2d::CCScene *v7; // rax\n  struct cocos2d::CCTransitionFade *v8; // rbx\n  __int64 v9; // rcx\n  cocos2d::CCDirector *v10; // rax\n  void *v11; // [rsp+30h] [rbp+8h]\n\n  if ( a1->m_searchObject )\n  {\n    a1->setKeypadEnabled(a1, 0);\n    a1->setKeyboardEnabled(a1, 0);\n    m_searchType = a1->m_searchObject->m_searchType;\n    v4 = SavedLevels;\n    if ( m_searchType == SavedLevels )\n      v4 = FavouriteLists;\n    v5 = qword_1406C2ED8;\n    if ( !qword_1406C2ED8 )\n    {\n      v11 = operator new(0x668u);\n      qword_1406C2ED8 = sub_14017AB00((__int64)v11);\n      (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);\n      v5 = qword_1406C2ED8;\n    }\n    *(_DWORD *)(v5 + 1204) = v4;\n    v6 = GJSearchObject::create_2(v4);\n    if ( m_searchType == SavedLevels )\n      v6->m_searchMode = 1;\n    v7 = LevelBrowserLayer::scene(v6);\n    v8 = cocos2d::CCTransitionFade::create(0.5, v7);\n    v10 = (cocos2d::CCDirector *)cocos2d::CCDirector::sharedDirector(v9);\n    cocos2d::CCDirector::replaceScene(v10, v8);\n  }\n}", "assembly": "; \n; LevelBrowserLayer::onSavedMode from 0x1402cdf70 to 0x1402ce050 (224 bytes)\n; \n; 2 xrefs:\n; > LevelBrowserLayer::init @ 0x1402ca15b\n; > <???> @ 0x1406d2d80\n; \n; This function is hookable on this platform!\n; \n; Using BromaIDA 8.0.0 @ https:;github.com/Stazzical/BromaIDA\n; Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https:;github.com/geode-sdk/bindings\n; \n\nmov     [rsp+arg_8], rbx                                               ; +0x0, 0x1402cdf70\npush    rdi                                                            ; +0x5, 0x1402cdf75\nsub     rsp, 20h                                                       ; +0x6, 0x1402cdf76\nmov     rbx, rcx                                                       ; +0xa, 0x1402cdf7a\ncmp     qword ptr [rcx+298h], 0                                        ; +0xd, 0x1402cdf7d\njz      loc_1402CE045                                                  ; +0x15, 0x1402cdf85\nmov     rax, [rcx]                                                     ; +0x1b, 0x1402cdf8b\nxor     edx, edx                                                       ; +0x1e, 0x1402cdf8e\ncall    qword ptr [rax+3D0h]                                           ; +0x20, 0x1402cdf90\nmov     rax, [rbx]                                                     ; +0x26, 0x1402cdf96\nxor     edx, edx                                                       ; +0x29, 0x1402cdf99\nmov     rcx, rbx                                                       ; +0x2b, 0x1402cdf9b\ncall    qword ptr [rax+3E0h]                                           ; +0x2e, 0x1402cdf9e\nmov     rax, [rbx+298h]                                                ; +0x34, 0x1402cdfa4\nmov     edi, [rax+140h]                                                ; +0x3b, 0x1402cdfab\nmov     ebx, 63h ; 'c'                                                 ; +0x41, 0x1402cdfb1\nmov     eax, 67h ; 'g'                                                 ; +0x46, 0x1402cdfb6\ncmp     edi, ebx                                                       ; +0x4b, 0x1402cdfbb\ncmovz   ebx, eax                                                       ; +0x4d, 0x1402cdfbd\nmov     rax, cs:qword_1406C2ED8                                        ; +0x50, 0x1402cdfc0\ntest    rax, rax                                                       ; +0x57, 0x1402cdfc7\njnz     short loc_1402CDFFB                                            ; +0x5a, 0x1402cdfca\nmov     ecx, 668h; Size                                                ; +0x5c, 0x1402cdfcc\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0x61, 0x1402cdfd1\nmov     [rsp+28h+arg_0], rax                                           ; +0x66, 0x1402cdfd6\nmov     rcx, rax                                                       ; +0x6b, 0x1402cdfdb\ncall    sub_14017AB00                                                  ; +0x6e, 0x1402cdfde\nnop                                                                    ; +0x73, 0x1402cdfe3\nmov     cs:qword_1406C2ED8, rax                                        ; +0x74, 0x1402cdfe4\nmov     rdx, [rax]                                                     ; +0x7b, 0x1402cdfeb\nmov     rcx, rax                                                       ; +0x7e, 0x1402cdfee\ncall    qword ptr [rdx+48h]                                            ; +0x81, 0x1402cdff1\nmov     rax, cs:qword_1406C2ED8                                        ; +0x84, 0x1402cdff4\nmov     [rax+4B4h], ebx                                                ; +0x8b, 0x1402cdffb\nmov     ecx, ebx                                                       ; +0x91, 0x1402ce001\ncall    GJSearchObject__create_2                                       ; +0x93, 0x1402ce003\ncmp     edi, 63h ; 'c'                                                 ; +0x98, 0x1402ce008\njnz     short loc_1402CE017                                            ; +0x9b, 0x1402ce00b\nmov     dword ptr [rax+1D0h], 1                                        ; +0x9d, 0x1402ce00d\nmov     rcx, rax                                                       ; +0xa7, 0x1402ce017\ncall    LevelBrowserLayer__scene                                       ; +0xaa, 0x1402ce01a\nmov     rdx, rax                                                       ; +0xaf, 0x1402ce01f\nmovss   xmm0, cs:dword_140622B08                                       ; +0xb2, 0x1402ce022\ncall    cs:?create@CCTransitionFade@cocos2d@@SAPEAV12@MPEAVCCScene@2@@Z; cocos2d::CCTransitionFade::create(float,cocos2d::CCScene *) ; +0xba, 0x1402ce02a\nmov     rbx, rax                                                       ; +0xc0, 0x1402ce030\ncall    cs:?sharedDirector@CCDirector@cocos2d@@SAPEAV12@XZ; cocos2d::CCDirector::sharedDirector(void) ; +0xc3, 0x1402ce033\nmov     rcx, rax                                                       ; +0xc9, 0x1402ce039\nmov     rdx, rbx                                                       ; +0xcc, 0x1402ce03c\ncall    cs:?replaceScene@CCDirector@cocos2d@@QEAA_NPEAVCCScene@2@@Z; cocos2d::CCDirector::replaceScene(cocos2d::CCScene *) ; +0xcf, 0x1402ce03f\nmov     rbx, [rsp+28h+arg_8]                                           ; +0xd5, 0x1402ce045\nadd     rsp, 20h                                                       ; +0xda, 0x1402ce04a\npop     rdi                                                            ; +0xde, 0x1402ce04e\nretn                                                                   ; +0xdf, 0x1402ce04f", "xrefs": ["LevelBrowserLayer::init @ 0x1402ca15b", "<???> @ 0x1406d2d80"], "is_objc": false, "is_arm32": false, "is_arm64": false, "bida_info": "8.0.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings"}