{"type": "func", "start": 4297582192, "end": 4297582529, "name": "EditorPauseLayer::onExport", "pseudocode": "// \n// EditorPauseLayer::onExport from 0x10027e670 to 0x10027e7c1 (337 bytes)\n// \n// 2 xrefs:\n// > EditorPauseLayer::customSetup @ 0x10027d795\n// > EditorPauseLayer::customSetup @ 0x10027dcfa\n// \n// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\n// \n// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n// Generated at Fri, 27 Nov 2026 12:27:42 +0000\n// \n\nvoid __fastcall EditorPauseLayer::onExport(__int64 a1, double a2)\n{\n  __int64 v2; // rax\n  __int64 v3; // rbx\n  __int64 v4; // rax\n  int v5; // eax\n  void **v6; // r14\n  __int64 v7; // rax\n  __int64 v8; // rax\n  _QWORD v9[2]; // [rsp+0h] [rbp-40h] BYREF\n  char *v10; // [rsp+10h] [rbp-30h] BYREF\n  char v11; // [rsp+18h] [rbp-28h] BYREF\n  char v12[39]; // [rsp+19h] [rbp-27h] BYREF\n\n  if ( !*(_BYTE *)(a1 + 568) )\n  {\n    v2 = LocalLevelManager::sharedState(a2);\n    sub_1004A5220(v2, 30.0);\n    LevelEditorLayer::saveLevel(*(_QWORD *)(a1 + 576));\n    v3 = sub_1007FE9A0(*(_QWORD *)(*(_QWORD *)(a1 + 576) + 1936LL));\n    v4 = LocalLevelManager::sharedState(30.0);\n    v5 = sub_1006CE060(v4, v3);\n    if ( v5 > 0 )\n    {\n      v11 = 30;\n      strcpy(v12, \"Level exported!\");\n      v6 = (void **)&v12[15];\n      v7 = FLAlertLayer::create_1(0, \"Exported\", &v11, \"OK\", 0, 300.0);\n      (*(void (__fastcall **)(__int64))(*(_QWORD *)v7 + 1312LL))(v7);\n      if ( (v11 & 1) == 0 )\n        return;\n      goto LABEL_4;\n    }\n    if ( !v5 )\n    {\n      v6 = (void **)&v10;\n      v10 = (char *)operator new(0x1Au);\n      v9[0] = 27;\n      v9[1] = 23;\n      strcpy(v10, \"Failed to export level.\");\n      v8 = FLAlertLayer::create_1(0, \"Error\", v9, \"OK\", 0, 300.0);\n      (*(void (__fastcall **)(__int64))(*(_QWORD *)v8 + 1312LL))(v8);\n      if ( (v9[0] & 1) != 0 )\nLABEL_4:\n        operator delete(*v6);\n    }\n  }\n}", "assembly": "; \n; EditorPauseLayer::onExport from 0x10027e670 to 0x10027e7c1 (337 bytes)\n; \n; 2 xrefs:\n; > EditorPauseLayer::customSetup @ 0x10027d795\n; > EditorPauseLayer::customSetup @ 0x10027dcfa\n; \n; This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\n; \n; Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n; Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n; Generated at Fri, 27 Nov 2026 12:27:42 +0000\n; \npush    rbp                                                            ; +0x0, 0x10027e670\nmov     rbp, rsp                                                       ; +0x1, 0x10027e671\npush    r14                                                            ; +0x4, 0x10027e674\npush    rbx                                                            ; +0x6, 0x10027e676\nsub     rsp, 30h                                                       ; +0x7, 0x10027e677\ncmp     byte ptr [rdi+238h], 0                                         ; +0xb, 0x10027e67b\njnz     loc_10027E7B8                                                  ; +0x12, 0x10027e682\nmov     rbx, rdi                                                       ; +0x18, 0x10027e688\ncall    LocalLevelManager__sharedState                                 ; +0x1b, 0x10027e68b\nmovsd   xmm0, cs:qword_100A072C8                                       ; +0x20, 0x10027e690\nmov     rdi, rax                                                       ; +0x28, 0x10027e698\ncall    sub_1004A5220                                                  ; +0x2b, 0x10027e69b\nmov     rdi, [rbx+240h]                                                ; +0x30, 0x10027e6a0\ncall    LevelEditorLayer__saveLevel                                    ; +0x37, 0x10027e6a7\nmov     rax, [rbx+240h]                                                ; +0x3c, 0x10027e6ac\nmov     rdi, [rax+790h]                                                ; +0x43, 0x10027e6b3\ncall    sub_1007FE9A0                                                  ; +0x4a, 0x10027e6ba\nmov     rbx, rax                                                       ; +0x4f, 0x10027e6bf\ncall    LocalLevelManager__sharedState                                 ; +0x52, 0x10027e6c2\nmov     rdi, rax                                                       ; +0x57, 0x10027e6c7\nmov     rsi, rbx                                                       ; +0x5a, 0x10027e6ca\ncall    sub_1006CE060                                                  ; +0x5d, 0x10027e6cd\ntest    eax, eax                                                       ; +0x62, 0x10027e6d2\njle     short loc_10027E742                                            ; +0x64, 0x10027e6d4\nmov     [rbp+var_28], 1Eh                                              ; +0x66, 0x10027e6d6\nmov     rax, 7865206C6576654Ch                                         ; +0x6a, 0x10027e6da\nmov     qword ptr [rbp+var_27], rax                                    ; +0x74, 0x10027e6e4\nmov     rax, 21646574726F7078h                                         ; +0x78, 0x10027e6e8\nmov     qword ptr [rbp+var_27+7], rax                                  ; +0x82, 0x10027e6f2\nlea     r14, [rbp+var_27+0Fh]                                          ; +0x86, 0x10027e6f6\nmov     [rbp+var_27+0Fh], 0                                            ; +0x8a, 0x10027e6fa\nlea     rsi, aExported; \"Exported\"                                     ; +0x8e, 0x10027e6fe\nlea     rcx, aOk; \"OK\"                                                 ; +0x95, 0x10027e705\nlea     rdx, [rbp+var_28]                                              ; +0x9c, 0x10027e70c\nmovss   xmm0, cs:dword_100A03734                                       ; +0xa0, 0x10027e710\nxor     edi, edi                                                       ; +0xa8, 0x10027e718\nxor     r8d, r8d                                                       ; +0xaa, 0x10027e71a\ncall    FLAlertLayer__create_1                                         ; +0xad, 0x10027e71d\nmov     rcx, [rax]                                                     ; +0xb2, 0x10027e722\nmov     rdi, rax                                                       ; +0xb5, 0x10027e725\ncall    qword ptr [rcx+520h]                                           ; +0xb8, 0x10027e728\ntest    [rbp+var_28], 1                                                ; +0xbe, 0x10027e72e\njz      loc_10027E7B8                                                  ; +0xc2, 0x10027e732\nmov     rdi, [r14]; __p                                                ; +0xc8, 0x10027e738\ncall    __ZdlPv; operator delete(void *)                               ; +0xcb, 0x10027e73b\njmp     short loc_10027E7B8                                            ; +0xd0, 0x10027e740\njnz     short loc_10027E7B8                                            ; +0xd2, 0x10027e742\nmov     edi, 1Ah; __sz                                                 ; +0xd4, 0x10027e744\ncall    __Znwm; operator new(ulong)                                    ; +0xd9, 0x10027e749\nlea     r14, [rbp+var_30]                                              ; +0xde, 0x10027e74e\nmov     [rbp+var_30], rax                                              ; +0xe2, 0x10027e752\nmov     [rbp+var_40], 1Bh                                              ; +0xe6, 0x10027e756\nmov     [rbp+var_38], 17h                                              ; +0xee, 0x10027e75e\nmov     rcx, 2E6C6576656C2074h                                         ; +0xf6, 0x10027e766\nmov     [rax+0Fh], rcx                                                 ; +0x100, 0x10027e770\nmovups  xmm0, xmmword ptr cs:aFailedToExport; \"Failed to export level.\" ; +0x104, 0x10027e774\nmovups  xmmword ptr [rax], xmm0                                        ; +0x10b, 0x10027e77b\nmov     byte ptr [rax+17h], 0                                          ; +0x10e, 0x10027e77e\nlea     rsi, aError; \"Error\"                                           ; +0x112, 0x10027e782\nlea     rcx, aOk; \"OK\"                                                 ; +0x119, 0x10027e789\nlea     rdx, [rbp+var_40]                                              ; +0x120, 0x10027e790\nmovss   xmm0, cs:dword_100A03734                                       ; +0x124, 0x10027e794\nxor     edi, edi                                                       ; +0x12c, 0x10027e79c\nxor     r8d, r8d                                                       ; +0x12e, 0x10027e79e\ncall    FLAlertLayer__create_1                                         ; +0x131, 0x10027e7a1\nmov     rcx, [rax]                                                     ; +0x136, 0x10027e7a6\nmov     rdi, rax                                                       ; +0x139, 0x10027e7a9\ncall    qword ptr [rcx+520h]                                           ; +0x13c, 0x10027e7ac\ntest    byte ptr [rbp+var_40], 1                                       ; +0x142, 0x10027e7b2\njnz     short loc_10027E738                                            ; +0x146, 0x10027e7b6\nadd     rsp, 30h                                                       ; +0x148, 0x10027e7b8\npop     rbx                                                            ; +0x14c, 0x10027e7bc\npop     r14                                                            ; +0x14d, 0x10027e7bd\npop     rbp                                                            ; +0x14f, 0x10027e7bf\nretn                                                                   ; +0x150, 0x10027e7c0", "xrefs": ["EditorPauseLayer::customSetup @ 0x10027d795", "EditorPauseLayer::customSetup @ 0x10027dcfa"], "is_objc": false, "is_32_bit": false, "is_64_bit": true, "idp_name": "pc", "bida_info": "8.3.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings"}