{"type": "func", "start": 5372075456, "end": 5372075597, "name": "MenuLayer::onGarage", "pseudocode": "// \n// MenuLayer::onGarage from 0x140335dc0 to 0x140335e4d (141 bytes)\n// \n// 3 xrefs:\n// > MenuLayer::keyDown @ 0x140336393\n// > MenuLayer::init @ 0x140333dc0\n// > <???> @ 0x1406d51e0\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\nvoid MenuLayer::onGarage(MenuLayer *a1, cocos2d::CCObject *a2)\n{\n  __int64 v2; // rax\n  struct cocos2d::CCScene *v3; // rax\n  struct cocos2d::CCTransitionFade *v4; // rbx\n  __int64 v5; // rcx\n  cocos2d::CCDirector *v6; // rax\n  void *v7; // [rsp+30h] [rbp+8h]\n\n  if ( !a1->m_showingTOS )\n  {\n    MenuLayer::willClose(a1);\n    v2 = qword_1406C2ED8;\n    if ( !qword_1406C2ED8 )\n    {\n      v7 = operator new(0x668u);\n      qword_1406C2ED8 = sub_14017AB00((__int64)v7);\n      (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);\n      v2 = qword_1406C2ED8;\n    }\n    *(_BYTE *)(v2 + 919) = 1;\n    v3 = GJGarageLayer::scene();\n    v4 = cocos2d::CCTransitionFade::create(0.5, v3);\n    v6 = (cocos2d::CCDirector *)cocos2d::CCDirector::sharedDirector(v5);\n    cocos2d::CCDirector::replaceScene(v6, v4);\n  }\n}", "assembly": "; \n; MenuLayer::onGarage from 0x140335dc0 to 0x140335e4d (141 bytes)\n; \n; 3 xrefs:\n; > MenuLayer::keyDown @ 0x140336393\n; > MenuLayer::init @ 0x140333dc0\n; > <???> @ 0x1406d51e0\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\npush    rbx                                                            ; +0x0, 0x140335dc0\nsub     rsp, 20h                                                       ; +0x2, 0x140335dc2\ncmp     byte ptr [rcx+1A8h], 0                                         ; +0x6, 0x140335dc6\njnz     short loc_140335E47                                            ; +0xd, 0x140335dcd\ncall    MenuLayer__willClose                                           ; +0xf, 0x140335dcf\nmov     rax, cs:qword_1406C2ED8                                        ; +0x14, 0x140335dd4\ntest    rax, rax                                                       ; +0x1b, 0x140335ddb\njnz     short loc_140335E0F                                            ; +0x1e, 0x140335dde\nmov     ecx, 668h; Size                                                ; +0x20, 0x140335de0\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0x25, 0x140335de5\nmov     [rsp+28h+arg_0], rax                                           ; +0x2a, 0x140335dea\nmov     rcx, rax                                                       ; +0x2f, 0x140335def\ncall    sub_14017AB00                                                  ; +0x32, 0x140335df2\nnop                                                                    ; +0x37, 0x140335df7\nmov     cs:qword_1406C2ED8, rax                                        ; +0x38, 0x140335df8\nmov     rdx, [rax]                                                     ; +0x3f, 0x140335dff\nmov     rcx, rax                                                       ; +0x42, 0x140335e02\ncall    qword ptr [rdx+48h]                                            ; +0x45, 0x140335e05\nmov     rax, cs:qword_1406C2ED8                                        ; +0x48, 0x140335e08\nmov     byte ptr [rax+397h], 1                                         ; +0x4f, 0x140335e0f\ncall    GJGarageLayer__scene                                           ; +0x56, 0x140335e16\nmov     rdx, rax                                                       ; +0x5b, 0x140335e1b\nmovss   xmm0, cs:dword_140622B08                                       ; +0x5e, 0x140335e1e\ncall    cs:?create@CCTransitionFade@cocos2d@@SAPEAV12@MPEAVCCScene@2@@Z; cocos2d::CCTransitionFade::create(float,cocos2d::CCScene *) ; +0x66, 0x140335e26\nmov     rbx, rax                                                       ; +0x6c, 0x140335e2c\ncall    cs:?sharedDirector@CCDirector@cocos2d@@SAPEAV12@XZ; cocos2d::CCDirector::sharedDirector(void) ; +0x6f, 0x140335e2f\nmov     rcx, rax                                                       ; +0x75, 0x140335e35\nmov     rdx, rbx                                                       ; +0x78, 0x140335e38\nadd     rsp, 20h                                                       ; +0x7b, 0x140335e3b\npop     rbx                                                            ; +0x7f, 0x140335e3f\njmp     cs:?replaceScene@CCDirector@cocos2d@@QEAA_NPEAVCCScene@2@@Z; cocos2d::CCDirector::replaceScene(cocos2d::CCScene *) ; +0x80, 0x140335e40\nadd     rsp, 20h                                                       ; +0x87, 0x140335e47\npop     rbx                                                            ; +0x8b, 0x140335e4b\nretn                                                                   ; +0x8c, 0x140335e4c", "xrefs": ["MenuLayer::keyDown @ 0x140336393", "MenuLayer::init @ 0x140333dc0", "<???> @ 0x1406d51e0"], "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"}