{"type": "func", "start": 4297669040, "end": 4297669339, "name": "EditorPauseLayer::onExitNoSave", "pseudocode": "// \n// EditorPauseLayer::onExitNoSave from 0x1002939b0 to 0x100293adb (299 bytes)\n// \n// 1 xrefs:\n// > EditorPauseLayer::customSetup @ 0x100291be9\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 __fastcall EditorPauseLayer::onExitNoSave(EditorPauseLayer *a1, cocos2d::CCObject *a2)\n{\n  __int64 v2; // rbx\n  FMODAudioEngine *v3; // rax\n  GameManager *v4; // rax\n  _QWORD v5[2]; // [rsp+0h] [rbp-20h] BYREF\n  void *__p; // [rsp+10h] [rbp-10h]\n\n  if ( !a1->m_saved )\n  {\n    if ( a1->m_editorLayer->m_level->m_levelType == Editor )\n    {\n      __p = operator new(0x48u);\n      v5[0] = 73;\n      v5[1] = 70;\n      strcpy((char *)__p, \"<cy>Exit</c> without saving? All unsaved changes will be <cr>lost</c>!\");\n      v2 = FLAlertLayer::create_1(&a1->FLAlertLayerProtocol, \"Exit\", v5, \"NO\", \"YES\", 300.0);\n      if ( (v5[0] & 1) != 0 )\n        operator delete(__p);\n      (*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)v2 + 72LL))(v2, 1);\n      (*(void (__fastcall **)(__int64))(*(_QWORD *)v2 + 1288LL))(v2);\n    }\n    else\n    {\n      v3 = FMODAudioEngine::sharedEngine();\n      FMODAudioEngine::unloadAllEffects(v3);\n      CCBlockLayer::decrementForcePrio(a1);\n      v4 = GameManager::sharedState();\n      GameManager::returnToLastScene(v4, a1->m_editorLayer->m_level);\n    }\n  }\n}", "assembly": "; \n; EditorPauseLayer::onExitNoSave from 0x1002939b0 to 0x100293adb (299 bytes)\n; \n; 1 xrefs:\n; > EditorPauseLayer::customSetup @ 0x100291be9\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    rbp                                                            ; +0x0, 0x1002939b0\nmov     rbp, rsp                                                       ; +0x1, 0x1002939b1\npush    rbx                                                            ; +0x4, 0x1002939b4\nsub     rsp, 18h                                                       ; +0x5, 0x1002939b5\ncmp     byte ptr [rdi+230h], 0                                         ; +0x9, 0x1002939b9\njnz     loc_100293A9B                                                  ; +0x10, 0x1002939c0\nmov     rax, [rdi+248h]                                                ; +0x16, 0x1002939c6\nmov     rax, [rax+790h]                                                ; +0x1d, 0x1002939cd\ncmp     dword ptr [rax+404h], 2                                        ; +0x24, 0x1002939d4\njnz     loc_100293AA2                                                  ; +0x2b, 0x1002939db\nadd     rdi, 228h                                                      ; +0x31, 0x1002939e1\nmov     rbx, rdi                                                       ; +0x38, 0x1002939e8\nmov     edi, 48h ; 'H'; __sz                                           ; +0x3b, 0x1002939eb\ncall    __Znwm; operator new(ulong)                                    ; +0x40, 0x1002939f0\nmov     [rbp+__p], rax                                                 ; +0x45, 0x1002939f5\nmov     [rbp+var_20], 49h ; 'I'                                        ; +0x49, 0x1002939f9\nmov     [rbp+var_18], 46h ; 'F'                                        ; +0x51, 0x100293a01\nmov     rcx, 213E632F3C74736Fh                                         ; +0x59, 0x100293a09\nmov     [rax+3Eh], rcx                                                 ; +0x63, 0x100293a13\nmovups  xmm0, xmmword ptr cs:aCyExitCWithout+30h; \" will be <cr>lost</c>!\" ; +0x67, 0x100293a17\nmovups  xmmword ptr [rax+30h], xmm0                                    ; +0x6e, 0x100293a1e\nmovups  xmm0, xmmword ptr cs:aCyExitCWithout+20h; \" unsaved changes will be <cr>lost</c>!\" ; +0x72, 0x100293a22\nmovups  xmmword ptr [rax+20h], xmm0                                    ; +0x79, 0x100293a29\nmovups  xmm0, xmmword ptr cs:aCyExitCWithout+10h; \"hout saving? All unsaved changes will b\"... ; +0x7d, 0x100293a2d\nmovups  xmmword ptr [rax+10h], xmm0                                    ; +0x84, 0x100293a34\nmovups  xmm0, xmmword ptr cs:aCyExitCWithout; \"<cy>Exit</c> without saving? All unsave\"... ; +0x88, 0x100293a38\nmovups  xmmword ptr [rax], xmm0                                        ; +0x8f, 0x100293a3f\nmov     byte ptr [rax+46h], 0                                          ; +0x92, 0x100293a42\nlea     rsi, aExit; \"Exit\"                                             ; +0x96, 0x100293a46\nlea     rcx, aNo; \"NO\"                                                 ; +0x9d, 0x100293a4d\nlea     r8, aYes_0; \"YES\"                                              ; +0xa4, 0x100293a54\nlea     rdx, [rbp+var_20]                                              ; +0xab, 0x100293a5b\nmovss   xmm0, cs:dword_1008152B4                                       ; +0xaf, 0x100293a5f\nmov     rdi, rbx                                                       ; +0xb7, 0x100293a67\ncall    FLAlertLayer__create_1                                         ; +0xba, 0x100293a6a\nmov     rbx, rax                                                       ; +0xbf, 0x100293a6f\ntest    byte ptr [rbp+var_20], 1                                       ; +0xc2, 0x100293a72\njz      short loc_100293A81                                            ; +0xc6, 0x100293a76\nmov     rdi, [rbp+__p]; __p                                            ; +0xc8, 0x100293a78\ncall    __ZdlPv; operator delete(void *)                               ; +0xcc, 0x100293a7c\nmov     rax, [rbx]                                                     ; +0xd1, 0x100293a81\nmov     rdi, rbx                                                       ; +0xd4, 0x100293a84\nmov     esi, 1                                                         ; +0xd7, 0x100293a87\ncall    qword ptr [rax+48h]                                            ; +0xdc, 0x100293a8c\nmov     rax, [rbx]                                                     ; +0xdf, 0x100293a8f\nmov     rdi, rbx                                                       ; +0xe2, 0x100293a92\ncall    qword ptr [rax+508h]                                           ; +0xe5, 0x100293a95\nadd     rsp, 18h                                                       ; +0xeb, 0x100293a9b\npop     rbx                                                            ; +0xef, 0x100293a9f\npop     rbp                                                            ; +0xf0, 0x100293aa0\nretn                                                                   ; +0xf1, 0x100293aa1\nmov     rbx, rdi                                                       ; +0xf2, 0x100293aa2\ncall    FMODAudioEngine__sharedEngine                                  ; +0xf5, 0x100293aa5\nmov     rdi, rax                                                       ; +0xfa, 0x100293aaa\ncall    FMODAudioEngine__unloadAllEffects                              ; +0xfd, 0x100293aad\nmov     rdi, rbx                                                       ; +0x102, 0x100293ab2\ncall    CCBlockLayer__decrementForcePrio                               ; +0x105, 0x100293ab5\ncall    GameManager__sharedState                                       ; +0x10a, 0x100293aba\nmov     rcx, [rbx+248h]                                                ; +0x10f, 0x100293abf\nmov     rsi, [rcx+790h]                                                ; +0x116, 0x100293ac6\nmov     rdi, rax                                                       ; +0x11d, 0x100293acd\nadd     rsp, 18h                                                       ; +0x120, 0x100293ad0\npop     rbx                                                            ; +0x124, 0x100293ad4\npop     rbp                                                            ; +0x125, 0x100293ad5\njmp     GameManager__returnToLastScene                                 ; +0x126, 0x100293ad6", "xrefs": ["EditorPauseLayer::customSetup @ 0x100291be9"], "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"}