{"type": "func", "start": 5371100528, "end": 5371101063, "name": "GameLevelManager::onAdminCloseCaseCompleted", "pseudocode": "// \n// GameLevelManager::onAdminCloseCaseCompleted from 0x140247d70 to 0x140247f87 (535 bytes)\n// \n// 2 xrefs:\n// > GameLevelManager::handleIt @ 0x14021ae76\n// > <???> @ 0x14091c2f8\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 11:28:39 +0000\n// \n\n// Hidden C++ exception states: #wind=3\nvoid __fastcall GameLevelManager::onAdminCloseCaseCompleted(__int64 a1, __int64 *a2, __int64 a3)\n{\n  _BYTE *v6; // rdx\n  size_t v7; // r8\n  __int64 v8; // r8\n  __int64 v9; // rdx\n  void *v10; // rcx\n  unsigned int v11; // r15d\n  const void *v12; // rcx\n  unsigned __int64 v13; // rsi\n  size_t v14; // r8\n  __int64 v15; // rcx\n  cocos2d::CCArray *v16; // rbp\n  cocos2d::CCString *v17; // rax\n  unsigned int v18; // esi\n  __int64 v19; // r9\n  cocos2d::CCString *v20; // rax\n  __int64 v21; // rcx\n  void *Block[2]; // [rsp+40h] [rbp-58h] BYREF\n  __int128 v23; // [rsp+50h] [rbp-48h]\n\n  v6 = (_BYTE *)a3;\n  if ( *(_QWORD *)(a3 + 24) > 0xFu )\n    v6 = *(_BYTE **)a3;\n  *(_OWORD *)Block = 0;\n  v23 = 0;\n  v7 = -1;\n  do\n    ++v7;\n  while ( v6[v7] );\n  sub_14003D230(Block, v6, v7);\n  cocos2d::CCDictionary::removeObjectForKey(*(_QWORD *)(a1 + 1200), Block);\n  v9 = *((_QWORD *)&v23 + 1);\n  if ( *((_QWORD *)&v23 + 1) > 0xFu )\n  {\n    v10 = Block[0];\n    if ( (unsigned __int64)(*((_QWORD *)&v23 + 1) + 1LL) >= 0x1000 )\n    {\n      v10 = *((void **)Block[0] - 1);\n      if ( (unsigned __int64)((char *)Block[0] - (char *)v10 - 8) > 0x1F )\n        invoke_watson(nullptr, nullptr, nullptr, 0, 0);\n    }\n    j_j_free(v10);\n  }\n  v11 = sub_140241F40((const char *)a3, v9, v8);\n  *(_OWORD *)Block = 0;\n  *(_QWORD *)&v23 = 2;\n  *((_QWORD *)&v23 + 1) = 15;\n  strcpy((char *)Block, \"-1\");\n  v12 = a2;\n  if ( (unsigned __int64)a2[3] > 0xF )\n    v12 = (const void *)*a2;\n  v13 = a2[2];\n  v14 = v13;\n  if ( v13 > 2 )\n    v14 = 2;\n  if ( !memcmp(v12, Block, v14) && v13 == 2 )\n  {\n    v15 = *(_QWORD *)(a1 + 1384);\n    if ( v15 )\n      (*(void (__fastcall **)(__int64, _QWORD))(*(_QWORD *)v15 + 344LL))(v15, v11);\n  }\n  else\n  {\n    v16 = sub_1400D2840(a2, \":\");\n    if ( cocos2d::CCArray::count(v16) )\n    {\n      v17 = cocos2d::CCArray::stringAtIndex(v16, 0);\n      v18 = cocos2d::CCString::intValue(v17);\n    }\n    else\n    {\n      v18 = 0;\n    }\n    LOBYTE(v19) = cocos2d::CCArray::count(v16) >= 2\n               && (v20 = cocos2d::CCArray::stringAtIndex(v16, 1u), cocos2d::CCString::intValue(v20));\n    v21 = *(_QWORD *)(a1 + 1384);\n    if ( v21 )\n      (*(void (__fastcall **)(__int64, _QWORD, _QWORD, __int64))(*(_QWORD *)v21 + 336LL))(v21, v11, v18, v19);\n  }\n  sub_14003D310((__int64)a2);\n  sub_14003D310(a3);\n}", "assembly": "; \n; GameLevelManager::onAdminCloseCaseCompleted from 0x140247d70 to 0x140247f87 (535 bytes)\n; \n; 2 xrefs:\n; > GameLevelManager::handleIt @ 0x14021ae76\n; > <???> @ 0x14091c2f8\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 11:28:39 +0000\n; \nmov     [rsp+arg_18], rbx                                              ; +0x0, 0x140247d70\npush    rbp                                                            ; +0x5, 0x140247d75\npush    rsi                                                            ; +0x6, 0x140247d76\npush    rdi                                                            ; +0x7, 0x140247d77\npush    r14                                                            ; +0x8, 0x140247d78\npush    r15                                                            ; +0xa, 0x140247d7a\nsub     rsp, 70h                                                       ; +0xc, 0x140247d7c\nmov     rax, cs:__security_cookie                                      ; +0x10, 0x140247d80\nxor     rax, rsp                                                       ; +0x17, 0x140247d87\nmov     [rsp+98h+var_38], rax                                          ; +0x1a, 0x140247d8a\nmov     rdi, r8                                                        ; +0x1f, 0x140247d8f\nmov     rbx, rdx                                                       ; +0x22, 0x140247d92\nmov     r14, rcx                                                       ; +0x25, 0x140247d95\nmov     [rsp+98h+var_68], rdx                                          ; +0x28, 0x140247d98\nmov     [rsp+98h+var_60], r8                                           ; +0x2d, 0x140247d9d\nmov     rdx, r8                                                        ; +0x32, 0x140247da2\ncmp     qword ptr [r8+18h], 0Fh                                        ; +0x35, 0x140247da5\njbe     short loc_140247DAF                                            ; +0x3a, 0x140247daa\nmov     rdx, [r8]                                                      ; +0x3c, 0x140247dac\nxorps   xmm0, xmm0                                                     ; +0x3f, 0x140247daf\nmovups  xmmword ptr [rsp+98h+Block], xmm0                              ; +0x42, 0x140247db2\nxorps   xmm1, xmm1                                                     ; +0x47, 0x140247db7\nmovdqu  [rsp+98h+var_48], xmm1                                         ; +0x4a, 0x140247dba\nmov     r8, 0FFFFFFFFFFFFFFFFh                                         ; +0x50, 0x140247dc0\nnop     word ptr [rax+rax+00000000h]                                   ; +0x57, 0x140247dc7\ninc     r8                                                             ; +0x60, 0x140247dd0\ncmp     byte ptr [rdx+r8], 0                                           ; +0x63, 0x140247dd3\njnz     short loc_140247DD0                                            ; +0x68, 0x140247dd8\nlea     rcx, [rsp+98h+Block]                                           ; +0x6a, 0x140247dda\ncall    sub_14003D230                                                  ; +0x6f, 0x140247ddf\nnop                                                                    ; +0x74, 0x140247de4\nlea     rdx, [rsp+98h+Block]                                           ; +0x75, 0x140247de5\nmov     rcx, [r14+4B0h]                                                ; +0x7a, 0x140247dea\ncall    cs:?removeObjectForKey@CCDictionary@cocos2d@@QEAAXAEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z; cocos2d::CCDictionary::removeObjectForKey(std::string const &) ; +0x81, 0x140247df1\nnop                                                                    ; +0x87, 0x140247df7\nmov     rdx, qword ptr [rsp+98h+var_48+8]                              ; +0x88, 0x140247df8\ncmp     rdx, 0Fh                                                       ; +0x8d, 0x140247dfd\njbe     short loc_140247E49                                            ; +0x91, 0x140247e01\ninc     rdx                                                            ; +0x93, 0x140247e03\nmov     rcx, [rsp+98h+Block]; Block                                    ; +0x96, 0x140247e06\nmov     rax, rcx                                                       ; +0x9b, 0x140247e0b\ncmp     rdx, 1000h                                                     ; +0x9e, 0x140247e0e\njb      short loc_140247E44                                            ; +0xa5, 0x140247e15\nadd     rdx, 27h ; '''                                                 ; +0xa7, 0x140247e17\nmov     rcx, [rcx-8]                                                   ; +0xab, 0x140247e1b\nsub     rax, rcx                                                       ; +0xaf, 0x140247e1f\nsub     rax, 8                                                         ; +0xb2, 0x140247e22\ncmp     rax, 1Fh                                                       ; +0xb6, 0x140247e26\njbe     short loc_140247E44                                            ; +0xba, 0x140247e2a\nxor     esi, esi                                                       ; +0xbc, 0x140247e2c\nmov     [rsp+98h+Reserved], rsi; Reserved                              ; +0xbe, 0x140247e2e\nxor     r9d, r9d; LineNo                                               ; +0xc3, 0x140247e33\nxor     r8d, r8d; FileName                                             ; +0xc6, 0x140247e36\nxor     edx, edx; FunctionName                                         ; +0xc9, 0x140247e39\nxor     ecx, ecx; Expression                                           ; +0xcb, 0x140247e3b\ncall    cs:_invoke_watson                                              ; +0xcd, 0x140247e3d\nalign 4                                                                ; +0xd3, 0x140247e43\ncall    j_j_free                                                       ; +0xd4, 0x140247e44\nmov     rcx, rdi                                                       ; +0xd9, 0x140247e49\ncall    sub_140241F40                                                  ; +0xdc, 0x140247e4c\nmov     r15d, eax                                                      ; +0xe1, 0x140247e51\nxorps   xmm0, xmm0                                                     ; +0xe4, 0x140247e54\nmovups  xmmword ptr [rsp+98h+Block], xmm0                              ; +0xe7, 0x140247e57\nmov     edx, 2                                                         ; +0xec, 0x140247e5c\nmov     qword ptr [rsp+98h+var_48], rdx                                ; +0xf1, 0x140247e61\nmov     qword ptr [rsp+98h+var_48+8], 0Fh                              ; +0xf6, 0x140247e66\nmov     eax, 312Dh                                                     ; +0xff, 0x140247e6f\nmov     word ptr [rsp+98h+Block], ax                                   ; +0x104, 0x140247e74\nmov     byte ptr [rsp+98h+Block+2], 0                                  ; +0x109, 0x140247e79\nmov     rcx, rbx                                                       ; +0x10e, 0x140247e7e\ncmp     qword ptr [rbx+18h], 0Fh                                       ; +0x111, 0x140247e81\njbe     short loc_140247E8B                                            ; +0x116, 0x140247e86\nmov     rcx, [rbx]; Buf1                                               ; +0x118, 0x140247e88\nmov     rsi, [rbx+10h]                                                 ; +0x11b, 0x140247e8b\nmov     r8, rsi                                                        ; +0x11f, 0x140247e8f\ncmp     rsi, rdx                                                       ; +0x122, 0x140247e92\ncmova   r8, rdx; Size                                                  ; +0x125, 0x140247e95\nlea     rdx, [rsp+98h+Block]; Buf2                                     ; +0x129, 0x140247e99\ncall    memcmp                                                         ; +0x12e, 0x140247e9e\ntest    eax, eax                                                       ; +0x133, 0x140247ea3\njnz     short loc_140247ECE                                            ; +0x135, 0x140247ea5\ncmp     rsi, 2                                                         ; +0x137, 0x140247ea7\njnz     short loc_140247ECE                                            ; +0x13b, 0x140247eab\nmov     rcx, [r14+568h]                                                ; +0x13d, 0x140247ead\ntest    rcx, rcx                                                       ; +0x144, 0x140247eb4\njz      loc_140247F55                                                  ; +0x147, 0x140247eb7\nmov     rax, [rcx]                                                     ; +0x14d, 0x140247ebd\nmov     edx, r15d                                                      ; +0x150, 0x140247ec0\ncall    qword ptr [rax+158h]                                           ; +0x153, 0x140247ec3\njmp     loc_140247F55                                                  ; +0x159, 0x140247ec9\nlea     rdx, asc_140727520; \":\"                                        ; +0x15e, 0x140247ece\nmov     rcx, rbx                                                       ; +0x165, 0x140247ed5\ncall    sub_1400D2840                                                  ; +0x168, 0x140247ed8\nmov     rbp, rax                                                       ; +0x16d, 0x140247edd\nmov     rcx, rax                                                       ; +0x170, 0x140247ee0\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x173, 0x140247ee3\ncmp     eax, 1                                                         ; +0x179, 0x140247ee9\njb      short loc_140247F06                                            ; +0x17c, 0x140247eec\nxor     edx, edx                                                       ; +0x17e, 0x140247eee\nmov     rcx, rbp                                                       ; +0x180, 0x140247ef0\ncall    cs:?stringAtIndex@CCArray@cocos2d@@QEAAPEAVCCString@2@I@Z; cocos2d::CCArray::stringAtIndex(uint) ; +0x183, 0x140247ef3\nmov     rcx, rax                                                       ; +0x189, 0x140247ef9\ncall    cs:?intValue@CCString@cocos2d@@QEBAHXZ; cocos2d::CCString::intValue(void) ; +0x18c, 0x140247efc\nmov     esi, eax                                                       ; +0x192, 0x140247f02\njmp     short loc_140247F08                                            ; +0x194, 0x140247f04\nxor     esi, esi                                                       ; +0x196, 0x140247f06\nmov     rcx, rbp                                                       ; +0x198, 0x140247f08\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x19b, 0x140247f0b\ncmp     eax, 2                                                         ; +0x1a1, 0x140247f11\njb      short loc_140247F36                                            ; +0x1a4, 0x140247f14\nmov     edx, 1                                                         ; +0x1a6, 0x140247f16\nmov     rcx, rbp                                                       ; +0x1ab, 0x140247f1b\ncall    cs:?stringAtIndex@CCArray@cocos2d@@QEAAPEAVCCString@2@I@Z; cocos2d::CCArray::stringAtIndex(uint) ; +0x1ae, 0x140247f1e\nmov     rcx, rax                                                       ; +0x1b4, 0x140247f24\ncall    cs:?intValue@CCString@cocos2d@@QEBAHXZ; cocos2d::CCString::intValue(void) ; +0x1b7, 0x140247f27\ntest    eax, eax                                                       ; +0x1bd, 0x140247f2d\njz      short loc_140247F36                                            ; +0x1bf, 0x140247f2f\nmov     r9b, 1                                                         ; +0x1c1, 0x140247f31\njmp     short loc_140247F39                                            ; +0x1c4, 0x140247f34\nxor     r9b, r9b                                                       ; +0x1c6, 0x140247f36\nmov     rcx, [r14+568h]                                                ; +0x1c9, 0x140247f39\ntest    rcx, rcx                                                       ; +0x1d0, 0x140247f40\njz      short loc_140247F55                                            ; +0x1d3, 0x140247f43\nmov     rax, [rcx]                                                     ; +0x1d5, 0x140247f45\nmov     r8d, esi                                                       ; +0x1d8, 0x140247f48\nmov     edx, r15d                                                      ; +0x1db, 0x140247f4b\ncall    qword ptr [rax+150h]                                           ; +0x1de, 0x140247f4e\nnop                                                                    ; +0x1e4, 0x140247f54\nmov     rcx, rbx                                                       ; +0x1e5, 0x140247f55\ncall    sub_14003D310                                                  ; +0x1e8, 0x140247f58\nnop                                                                    ; +0x1ed, 0x140247f5d\nmov     rcx, rdi                                                       ; +0x1ee, 0x140247f5e\ncall    sub_14003D310                                                  ; +0x1f1, 0x140247f61\nmov     rcx, [rsp+98h+var_38]                                          ; +0x1f6, 0x140247f66\nxor     rcx, rsp; StackCookie                                          ; +0x1fb, 0x140247f6b\ncall    __security_check_cookie                                        ; +0x1fe, 0x140247f6e\nmov     rbx, [rsp+98h+arg_18]                                          ; +0x203, 0x140247f73\nadd     rsp, 70h                                                       ; +0x20b, 0x140247f7b\npop     r15                                                            ; +0x20f, 0x140247f7f\npop     r14                                                            ; +0x211, 0x140247f81\npop     rdi                                                            ; +0x213, 0x140247f83\npop     rsi                                                            ; +0x214, 0x140247f84\npop     rbp                                                            ; +0x215, 0x140247f85\nretn                                                                   ; +0x216, 0x140247f86", "xrefs": ["GameLevelManager::handleIt @ 0x14021ae76", "<???> @ 0x14091c2f8"], "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"}