{"type": "func", "start": 4296936544, "end": 4296937272, "name": "EditLevelLayer::FLAlert_Clicked", "pseudocode": "// \n// EditLevelLayer::FLAlert_Clicked from 0x1001e0c60 to 0x1001e0f38 (728 bytes)\n// \n// 2 xrefs:\n// > sub_1001E10E0 @ 0x1001e10ec\n// > <???> @ 0x100ade978\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:26:28 +0000\n// \n\nvoid __fastcall EditLevelLayer::FLAlert_Clicked(__int64 a1, const void *a2, unsigned __int8 a3, double a4)\n{\n  unsigned __int8 v5; // r12\n  double v6; // xmm0_8\n  __int64 v7; // rax\n  __int64 v8; // rsi\n  double v9; // xmm0_8\n  __int64 v10; // rax\n  __int64 v11; // rax\n  __int64 v12; // rdx\n  __int64 v13; // rdx\n  double v14; // xmm0_8\n  __int64 v15; // rax\n  __int64 v16; // r14\n  __int64 v17; // rax\n  unsigned int v18; // r15d\n  __int128 *v19; // rax\n  char updated; // r14\n  __int64 v21; // rax\n  __int64 v22; // rax\n  void *v23[3]; // [rsp+8h] [rbp-58h] BYREF\n  __int128 v24; // [rsp+20h] [rbp-40h] BYREF\n  void *__p; // [rsp+30h] [rbp-30h]\n\n  v5 = a3 ^ 1;\n  if ( a3 ^ 1 | ((*(unsigned int (__fastcall **)(const void *))(*(_QWORD *)a2 + 64LL))(a2) != 4) )\n  {\n    if ( v5 | ((*(unsigned int (__fastcall **)(const void *))(*(_QWORD *)a2 + 64LL))(a2) != 7) )\n    {\n      if ( v5 | ((*(unsigned int (__fastcall **)(const void *))(*(_QWORD *)a2 + 64LL))(a2) != 8) )\n      {\n        if ( v5 | ((*(unsigned int (__fastcall **)(const void *))(*(_QWORD *)a2 + 64LL))(a2) != 12) )\n        {\n          if ( (*(unsigned int (__fastcall **)(const void *))(*(_QWORD *)a2 + 64LL))(a2) == 10 )\n          {\n            EditLevelLayer::onShare(a1, a2, v12);\n          }\n          else if ( (*(unsigned int (__fastcall **)(const void *))(*(_QWORD *)a2 + 64LL))(a2) == 5 )\n          {\n            if ( a3 )\n            {\n              *(_QWORD *)&v14 = GameManager::sharedState(a2, a2, v13).u64[0];\n              GameManager::openEditorGuide(v15, v14);\n            }\n            else\n            {\n              EditLevelLayer::onEdit(a1, (__int64)a2);\n            }\n          }\n          else if ( v5 | ((*(unsigned int (__fastcall **)(const void *))(*(_QWORD *)a2 + 64LL))(a2) != 9) )\n          {\n            if ( (*(unsigned int (__fastcall **)(const void *))(*(_QWORD *)a2 + 64LL))(a2) == 11 )\n            {\n              if ( a3 )\n                *(_BYTE *)(a1 + 536) = 1;\n              else\n                sub_1005839A0(*(_QWORD *)(a1 + 472));\n              EditLevelLayer::onPlay(a1, (__int64)a2);\n            }\n          }\n          else\n          {\n            EditLevelLayer::closeTextInputs(a1);\n            *(_QWORD *)(GameLevelManager::sharedState(a4) + 1360) = a1 + 424;\n            v16 = GameLevelManager::sharedState(a4);\n            v17 = *(_QWORD *)(a1 + 472);\n            v18 = *(_DWORD *)(v17 + 328) - *(_DWORD *)(v17 + 332);\n            if ( (*(_BYTE *)(v17 + 368) & 1) != 0 )\n            {\n              sub_10001AD30(&v24, *(const void **)(v17 + 384), *(_QWORD *)(v17 + 376));\n            }\n            else\n            {\n              v19 = (__int128 *)(v17 + 368);\n              __p = *((void **)v19 + 2);\n              v24 = *v19;\n            }\n            updated = GameLevelManager::updateDescription(v16, v18, &v24);\n            if ( (v24 & 1) != 0 )\n              operator delete(__p);\n            if ( updated )\n            {\n              v21 = *(_QWORD *)(a1 + 528);\n              if ( v21 )\n              {\n                *(_QWORD *)(v21 + 664) = 0;\n                *(_QWORD *)(a1 + 528) = 0;\n              }\n              sub_10000E4E0(v23, \"Updating description...\");\n              v22 = UploadActionPopup::create(a1 + 432, v23);\n              *(_QWORD *)(a1 + 528) = v22;\n              if ( ((__int64)v23[0] & 1) != 0 )\n              {\n                operator delete(v23[2]);\n                v22 = *(_QWORD *)(a1 + 528);\n              }\n              (*(void (__fastcall **)(__int64))(*(_QWORD *)v22 + 1312LL))(v22);\n            }\n          }\n        }\n        else\n        {\n          v11 = LocalLevelManager::sharedState(a4);\n          sub_1006CA9C0(v11, *(_QWORD *)(a1 + 472));\n        }\n      }\n      else\n      {\n        v10 = LocalLevelManager::sharedState(a4);\n        LocalLevelManager::moveLevelToTop(v10, *(_QWORD *)(a1 + 472));\n      }\n    }\n    else\n    {\n      EditLevelLayer::onClone(a1);\n    }\n  }\n  else\n  {\n    v6 = (*(double (__fastcall **)(_QWORD, _QWORD))(**(_QWORD **)(a1 + 464) + 1272LL))(*(_QWORD *)(a1 + 464), 0);\n    v7 = GameLevelManager::sharedState(v6);\n    v8 = *(_QWORD *)(a1 + 472);\n    v9 = GameLevelManager::deleteLevel(v7, v8);\n    EditLevelLayer::onBack((_QWORD *)a1, v8, v9);\n  }\n}", "assembly": "; \n; EditLevelLayer::FLAlert_Clicked from 0x1001e0c60 to 0x1001e0f38 (728 bytes)\n; \n; 2 xrefs:\n; > sub_1001E10E0 @ 0x1001e10ec\n; > <???> @ 0x100ade978\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:26:28 +0000\n; \npush    rbp                                                            ; +0x0, 0x1001e0c60\nmov     rbp, rsp                                                       ; +0x1, 0x1001e0c61\npush    r15                                                            ; +0x4, 0x1001e0c64\npush    r14                                                            ; +0x6, 0x1001e0c66\npush    r12                                                            ; +0x8, 0x1001e0c68\npush    rbx                                                            ; +0xa, 0x1001e0c6a\nsub     rsp, 40h                                                       ; +0xb, 0x1001e0c6b\nmov     r14d, edx                                                      ; +0xf, 0x1001e0c6f\nmov     r15, rsi                                                       ; +0x12, 0x1001e0c72\nmov     rbx, rdi                                                       ; +0x15, 0x1001e0c75\nmov     r12d, r14d                                                     ; +0x18, 0x1001e0c78\nxor     r12b, 1                                                        ; +0x1b, 0x1001e0c7b\nmov     rax, [rsi]                                                     ; +0x1f, 0x1001e0c7f\nmov     rdi, rsi                                                       ; +0x22, 0x1001e0c82\ncall    qword ptr [rax+40h]                                            ; +0x25, 0x1001e0c85\ncmp     eax, 4                                                         ; +0x28, 0x1001e0c88\nsetnz   al                                                             ; +0x2b, 0x1001e0c8b\nor      al, r12b                                                       ; +0x2e, 0x1001e0c8e\njnz     short loc_1001E0CCD                                            ; +0x31, 0x1001e0c91\nmov     rdi, [rbx+1D0h]                                                ; +0x33, 0x1001e0c93\nmov     rax, [rdi]                                                     ; +0x3a, 0x1001e0c9a\nxor     esi, esi                                                       ; +0x3d, 0x1001e0c9d\ncall    qword ptr [rax+4F8h]                                           ; +0x3f, 0x1001e0c9f\ncall    GameLevelManager__sharedState                                  ; +0x45, 0x1001e0ca5\nmov     rsi, [rbx+1D8h]                                                ; +0x4a, 0x1001e0caa\nmov     rdi, rax                                                       ; +0x51, 0x1001e0cb1\ncall    GameLevelManager__deleteLevel                                  ; +0x54, 0x1001e0cb4\nmov     rdi, rbx                                                       ; +0x59, 0x1001e0cb9\nadd     rsp, 40h                                                       ; +0x5c, 0x1001e0cbc\npop     rbx                                                            ; +0x60, 0x1001e0cc0\npop     r12                                                            ; +0x61, 0x1001e0cc1\npop     r14                                                            ; +0x63, 0x1001e0cc3\npop     r15                                                            ; +0x65, 0x1001e0cc5\npop     rbp                                                            ; +0x67, 0x1001e0cc7\njmp     EditLevelLayer__onBack                                         ; +0x68, 0x1001e0cc8\nmov     rax, [r15]                                                     ; +0x6d, 0x1001e0ccd\nmov     rdi, r15                                                       ; +0x70, 0x1001e0cd0\ncall    qword ptr [rax+40h]                                            ; +0x73, 0x1001e0cd3\ncmp     eax, 7                                                         ; +0x76, 0x1001e0cd6\nsetnz   al                                                             ; +0x79, 0x1001e0cd9\nor      al, r12b                                                       ; +0x7c, 0x1001e0cdc\njnz     short loc_1001E0CF5                                            ; +0x7f, 0x1001e0cdf\nmov     rdi, rbx                                                       ; +0x81, 0x1001e0ce1\nadd     rsp, 40h                                                       ; +0x84, 0x1001e0ce4\npop     rbx                                                            ; +0x88, 0x1001e0ce8\npop     r12                                                            ; +0x89, 0x1001e0ce9\npop     r14                                                            ; +0x8b, 0x1001e0ceb\npop     r15                                                            ; +0x8d, 0x1001e0ced\npop     rbp                                                            ; +0x8f, 0x1001e0cef\njmp     EditLevelLayer__onClone                                        ; +0x90, 0x1001e0cf0\nmov     rax, [r15]                                                     ; +0x95, 0x1001e0cf5\nmov     rdi, r15                                                       ; +0x98, 0x1001e0cf8\ncall    qword ptr [rax+40h]                                            ; +0x9b, 0x1001e0cfb\ncmp     eax, 8                                                         ; +0x9e, 0x1001e0cfe\nsetnz   al                                                             ; +0xa1, 0x1001e0d01\nor      al, r12b                                                       ; +0xa4, 0x1001e0d04\njnz     short loc_1001E0D29                                            ; +0xa7, 0x1001e0d07\ncall    LocalLevelManager__sharedState                                 ; +0xa9, 0x1001e0d09\nmov     rsi, [rbx+1D8h]                                                ; +0xae, 0x1001e0d0e\nmov     rdi, rax                                                       ; +0xb5, 0x1001e0d15\nadd     rsp, 40h                                                       ; +0xb8, 0x1001e0d18\npop     rbx                                                            ; +0xbc, 0x1001e0d1c\npop     r12                                                            ; +0xbd, 0x1001e0d1d\npop     r14                                                            ; +0xbf, 0x1001e0d1f\npop     r15                                                            ; +0xc1, 0x1001e0d21\npop     rbp                                                            ; +0xc3, 0x1001e0d23\njmp     LocalLevelManager__moveLevelToTop                              ; +0xc4, 0x1001e0d24\nmov     rax, [r15]                                                     ; +0xc9, 0x1001e0d29\nmov     rdi, r15                                                       ; +0xcc, 0x1001e0d2c\ncall    qword ptr [rax+40h]                                            ; +0xcf, 0x1001e0d2f\ncmp     eax, 0Ch                                                       ; +0xd2, 0x1001e0d32\nsetnz   al                                                             ; +0xd5, 0x1001e0d35\nor      al, r12b                                                       ; +0xd8, 0x1001e0d38\njnz     short loc_1001E0D5D                                            ; +0xdb, 0x1001e0d3b\ncall    LocalLevelManager__sharedState                                 ; +0xdd, 0x1001e0d3d\nmov     rsi, [rbx+1D8h]                                                ; +0xe2, 0x1001e0d42\nmov     rdi, rax                                                       ; +0xe9, 0x1001e0d49\nadd     rsp, 40h                                                       ; +0xec, 0x1001e0d4c\npop     rbx                                                            ; +0xf0, 0x1001e0d50\npop     r12                                                            ; +0xf1, 0x1001e0d51\npop     r14                                                            ; +0xf3, 0x1001e0d53\npop     r15                                                            ; +0xf5, 0x1001e0d55\npop     rbp                                                            ; +0xf7, 0x1001e0d57\njmp     sub_1006CA9C0                                                  ; +0xf8, 0x1001e0d58\nmov     rax, [r15]                                                     ; +0xfd, 0x1001e0d5d\nmov     rdi, r15                                                       ; +0x100, 0x1001e0d60\ncall    qword ptr [rax+40h]                                            ; +0x103, 0x1001e0d63\ncmp     eax, 0Ah                                                       ; +0x106, 0x1001e0d66\njnz     short loc_1001E0D7F                                            ; +0x109, 0x1001e0d69\nmov     rdi, rbx                                                       ; +0x10b, 0x1001e0d6b\nadd     rsp, 40h                                                       ; +0x10e, 0x1001e0d6e\npop     rbx                                                            ; +0x112, 0x1001e0d72\npop     r12                                                            ; +0x113, 0x1001e0d73\npop     r14                                                            ; +0x115, 0x1001e0d75\npop     r15                                                            ; +0x117, 0x1001e0d77\npop     rbp                                                            ; +0x119, 0x1001e0d79\njmp     EditLevelLayer__onShare                                        ; +0x11a, 0x1001e0d7a\nmov     rax, [r15]                                                     ; +0x11f, 0x1001e0d7f\nmov     rdi, r15                                                       ; +0x122, 0x1001e0d82\ncall    qword ptr [rax+40h]                                            ; +0x125, 0x1001e0d85\ncmp     eax, 5                                                         ; +0x128, 0x1001e0d88\njnz     short loc_1001E0DAF                                            ; +0x12b, 0x1001e0d8b\ntest    r14b, r14b                                                     ; +0x12d, 0x1001e0d8d\njz      loc_1001E0E1B                                                  ; +0x130, 0x1001e0d90\ncall    GameManager__sharedState                                       ; +0x136, 0x1001e0d96\nmov     rdi, rax                                                       ; +0x13b, 0x1001e0d9b\nadd     rsp, 40h                                                       ; +0x13e, 0x1001e0d9e\npop     rbx                                                            ; +0x142, 0x1001e0da2\npop     r12                                                            ; +0x143, 0x1001e0da3\npop     r14                                                            ; +0x145, 0x1001e0da5\npop     r15                                                            ; +0x147, 0x1001e0da7\npop     rbp                                                            ; +0x149, 0x1001e0da9\njmp     GameManager__openEditorGuide                                   ; +0x14a, 0x1001e0daa\nmov     rax, [r15]                                                     ; +0x14f, 0x1001e0daf\nmov     rdi, r15                                                       ; +0x152, 0x1001e0db2\ncall    qword ptr [rax+40h]                                            ; +0x155, 0x1001e0db5\ncmp     eax, 9                                                         ; +0x158, 0x1001e0db8\nsetnz   al                                                             ; +0x15b, 0x1001e0dbb\nor      al, r12b                                                       ; +0x15e, 0x1001e0dbe\njnz     short loc_1001E0E2F                                            ; +0x161, 0x1001e0dc1\nmov     rdi, rbx                                                       ; +0x163, 0x1001e0dc3\ncall    EditLevelLayer__closeTextInputs                                ; +0x166, 0x1001e0dc6\ncall    GameLevelManager__sharedState                                  ; +0x16b, 0x1001e0dcb\nlea     rcx, [rbx+1A8h]                                                ; +0x170, 0x1001e0dd0\nmov     [rax+550h], rcx                                                ; +0x177, 0x1001e0dd7\ncall    GameLevelManager__sharedState                                  ; +0x17e, 0x1001e0dde\nmov     r14, rax                                                       ; +0x183, 0x1001e0de3\nmov     rax, [rbx+1D8h]                                                ; +0x186, 0x1001e0de6\nmov     r15d, [rax+148h]                                               ; +0x18d, 0x1001e0ded\nsub     r15d, [rax+14Ch]                                               ; +0x194, 0x1001e0df4\ntest    byte ptr [rax+170h], 1                                         ; +0x19b, 0x1001e0dfb\njnz     short loc_1001E0E56                                            ; +0x1a2, 0x1001e0e02\nadd     rax, 170h                                                      ; +0x1a4, 0x1001e0e04\nmov     rcx, [rax+10h]                                                 ; +0x1aa, 0x1001e0e0a\nmov     [rbp+__p], rcx                                                 ; +0x1ae, 0x1001e0e0e\nmovups  xmm0, xmmword ptr [rax]                                        ; +0x1b2, 0x1001e0e12\nmovaps  [rbp+var_40], xmm0                                             ; +0x1b5, 0x1001e0e15\njmp     short loc_1001E0E6D                                            ; +0x1b9, 0x1001e0e19\nmov     rdi, rbx                                                       ; +0x1bb, 0x1001e0e1b\nadd     rsp, 40h                                                       ; +0x1be, 0x1001e0e1e\npop     rbx                                                            ; +0x1c2, 0x1001e0e22\npop     r12                                                            ; +0x1c3, 0x1001e0e23\npop     r14                                                            ; +0x1c5, 0x1001e0e25\npop     r15                                                            ; +0x1c7, 0x1001e0e27\npop     rbp                                                            ; +0x1c9, 0x1001e0e29\njmp     EditLevelLayer__onEdit                                         ; +0x1ca, 0x1001e0e2a\nmov     rax, [r15]                                                     ; +0x1cf, 0x1001e0e2f\nmov     rdi, r15                                                       ; +0x1d2, 0x1001e0e32\ncall    qword ptr [rax+40h]                                            ; +0x1d5, 0x1001e0e35\ncmp     eax, 0Bh                                                       ; +0x1d8, 0x1001e0e38\njnz     loc_1001E0F0B                                                  ; +0x1db, 0x1001e0e3b\ntest    r14b, r14b                                                     ; +0x1e1, 0x1001e0e41\njz      loc_1001E0F18                                                  ; +0x1e4, 0x1001e0e44\nmov     byte ptr [rbx+218h], 1                                         ; +0x1ea, 0x1001e0e4a\njmp     loc_1001E0F24                                                  ; +0x1f1, 0x1001e0e51\nmov     rdx, [rax+178h]                                                ; +0x1f6, 0x1001e0e56\nmov     rsi, [rax+180h]                                                ; +0x1fd, 0x1001e0e5d\nlea     rdi, [rbp+var_40]                                              ; +0x204, 0x1001e0e64\ncall    sub_10001AD30                                                  ; +0x208, 0x1001e0e68\nlea     r12, [rbp+__p]                                                 ; +0x20d, 0x1001e0e6d\nlea     rdx, [rbp+var_40]                                              ; +0x211, 0x1001e0e71\nmov     rdi, r14                                                       ; +0x215, 0x1001e0e75\nmov     esi, r15d                                                      ; +0x218, 0x1001e0e78\ncall    GameLevelManager__updateDescription                            ; +0x21b, 0x1001e0e7b\nmov     r14d, eax                                                      ; +0x220, 0x1001e0e80\ntest    byte ptr [rbp+var_40], 1                                       ; +0x223, 0x1001e0e83\njz      short loc_1001E0E92                                            ; +0x227, 0x1001e0e87\nmov     rdi, [rbp+__p]; __p                                            ; +0x229, 0x1001e0e89\ncall    __ZdlPv; operator delete(void *)                               ; +0x22d, 0x1001e0e8d\ntest    r14b, r14b                                                     ; +0x232, 0x1001e0e92\njz      short loc_1001E0F0B                                            ; +0x235, 0x1001e0e95\nmov     rax, [rbx+210h]                                                ; +0x237, 0x1001e0e97\ntest    rax, rax                                                       ; +0x23e, 0x1001e0e9e\njz      short loc_1001E0EB9                                            ; +0x241, 0x1001e0ea1\nmov     qword ptr [rax+298h], 0                                        ; +0x243, 0x1001e0ea3\nmov     qword ptr [rbx+210h], 0                                        ; +0x24e, 0x1001e0eae\nlea     r12, [rbp+var_48]                                              ; +0x259, 0x1001e0eb9\nlea     r14, [rbx+1B0h]                                                ; +0x25d, 0x1001e0ebd\nlea     rsi, aUpdatingDescri; \"Updating description...\"                ; +0x264, 0x1001e0ec4\nlea     r15, [rbp+var_58]                                              ; +0x26b, 0x1001e0ecb\nmov     rdi, r15                                                       ; +0x26f, 0x1001e0ecf\ncall    sub_10000E4E0                                                  ; +0x272, 0x1001e0ed2\nmov     rdi, r14                                                       ; +0x277, 0x1001e0ed7\nmov     rsi, r15                                                       ; +0x27a, 0x1001e0eda\ncall    UploadActionPopup__create                                      ; +0x27d, 0x1001e0edd\nmov     [rbx+210h], rax                                                ; +0x282, 0x1001e0ee2\ntest    [rbp+var_58], 1                                                ; +0x289, 0x1001e0ee9\njz      short loc_1001E0EFF                                            ; +0x28d, 0x1001e0eed\nmov     rdi, [rbp+var_48]; __p                                         ; +0x28f, 0x1001e0eef\ncall    __ZdlPv; operator delete(void *)                               ; +0x293, 0x1001e0ef3\nmov     rax, [rbx+210h]                                                ; +0x298, 0x1001e0ef8\nmov     rcx, [rax]                                                     ; +0x29f, 0x1001e0eff\nmov     rdi, rax                                                       ; +0x2a2, 0x1001e0f02\ncall    qword ptr [rcx+520h]                                           ; +0x2a5, 0x1001e0f05\nadd     rsp, 40h                                                       ; +0x2ab, 0x1001e0f0b\npop     rbx                                                            ; +0x2af, 0x1001e0f0f\npop     r12                                                            ; +0x2b0, 0x1001e0f10\npop     r14                                                            ; +0x2b2, 0x1001e0f12\npop     r15                                                            ; +0x2b4, 0x1001e0f14\npop     rbp                                                            ; +0x2b6, 0x1001e0f16\nretn                                                                   ; +0x2b7, 0x1001e0f17\nmov     rdi, [rbx+1D8h]                                                ; +0x2b8, 0x1001e0f18\ncall    sub_1005839A0                                                  ; +0x2bf, 0x1001e0f1f\nmov     rdi, rbx                                                       ; +0x2c4, 0x1001e0f24\nadd     rsp, 40h                                                       ; +0x2c7, 0x1001e0f27\npop     rbx                                                            ; +0x2cb, 0x1001e0f2b\npop     r12                                                            ; +0x2cc, 0x1001e0f2c\npop     r14                                                            ; +0x2ce, 0x1001e0f2e\npop     r15                                                            ; +0x2d0, 0x1001e0f30\npop     rbp                                                            ; +0x2d2, 0x1001e0f32\njmp     EditLevelLayer__onPlay                                         ; +0x2d3, 0x1001e0f33", "xrefs": ["sub_1001E10E0 @ 0x1001e10ec", "<???> @ 0x100ade978"], "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"}