{"type": "func", "start": 6442456032, "end": 6442456240, "name": "sub_1800013E0", "pseudocode": "// \n// sub_1800013E0 from 0x1800013e0 to 0x1800014b0 (208 bytes)\n// \n// 2 xrefs:\n// > <???> @ 0x1800259d8\n// > <???> @ 0x18004b048\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:15:34 +0000\n// \n\n// Hidden C++ exception states: #wind=1\n_QWORD *__fastcall sub_1800013E0(_QWORD *Block, char a2)\n{\n  cocos2d::CCObject *v5; // rcx\n\n  if ( (a2 & 2) != 0 )\n  {\n    sub_18001F0B0(Block, 208, *(Block - 1), cocos2d::extension::AssetsManager::~AssetsManager);\n    if ( (a2 & 1) != 0 )\n      j_j_j_free(Block - 1);\n    return Block - 1;\n  }\n  else\n  {\n    *Block = &cocos2d::extension::AssetsManager::`vftable';\n    v5 = (cocos2d::CCObject *)Block[22];\n    if ( v5 )\n      cocos2d::CCObject::release(v5);\n    sub_180003700(Block + 17);\n    sub_180003700(Block + 13);\n    sub_180003700(Block + 9);\n    sub_180003700(Block + 5);\n    sub_180003700(Block + 1);\n    if ( (a2 & 1) != 0 )\n      j_j_free(Block);\n    return Block;\n  }\n}", "assembly": "; \n; sub_1800013E0 from 0x1800013e0 to 0x1800014b0 (208 bytes)\n; \n; 2 xrefs:\n; > <???> @ 0x1800259d8\n; > <???> @ 0x18004b048\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:15:34 +0000\n; \nmov     [rsp+arg_0], rbx                                               ; +0x0, 0x1800013e0\nmov     [rsp+arg_8], rsi                                               ; +0x5, 0x1800013e5\npush    rdi                                                            ; +0xa, 0x1800013ea\nsub     rsp, 20h                                                       ; +0xb, 0x1800013eb\nmov     esi, edx                                                       ; +0xf, 0x1800013ef\nmov     rbx, rcx                                                       ; +0x11, 0x1800013f1\ntest    dl, 2                                                          ; +0x14, 0x1800013f4\njz      short loc_18000143D                                            ; +0x17, 0x1800013f7\nlea     r9, ??1AssetsManager@extension@cocos2d@@UEAA@XZ; cocos2d::extension::AssetsManager::~AssetsManager(void) ; +0x19, 0x1800013f9\nmov     r8, [rcx-8]                                                    ; +0x20, 0x180001400\nmov     edx, 0D0h                                                      ; +0x24, 0x180001404\ncall    sub_18001F0B0                                                  ; +0x29, 0x180001409\ntest    sil, 1                                                         ; +0x2e, 0x18000140e\njz      short loc_180001429                                            ; +0x32, 0x180001412\nimul    rdx, [rbx-8], 0D0h                                             ; +0x34, 0x180001414\nadd     rdx, 8                                                         ; +0x3c, 0x18000141c\nlea     rcx, [rbx-8]; Block                                            ; +0x40, 0x180001420\ncall    j_j_j_free                                                     ; +0x44, 0x180001424\nlea     rax, [rbx-8]                                                   ; +0x49, 0x180001429\nmov     rbx, [rsp+28h+arg_0]                                           ; +0x4d, 0x18000142d\nmov     rsi, [rsp+28h+arg_8]                                           ; +0x52, 0x180001432\nadd     rsp, 20h                                                       ; +0x57, 0x180001437\npop     rdi                                                            ; +0x5b, 0x18000143b\nretn                                                                   ; +0x5c, 0x18000143c\nlea     rax, ??_7AssetsManager@extension@cocos2d@@6B@; const cocos2d::extension::AssetsManager::`vftable' ; +0x5d, 0x18000143d\nmov     [rcx], rax                                                     ; +0x64, 0x180001444\nmov     rcx, [rcx+0B0h]                                                ; +0x67, 0x180001447\ntest    rcx, rcx                                                       ; +0x6e, 0x18000144e\njz      short loc_180001459                                            ; +0x71, 0x180001451\ncall    cs:?release@CCObject@cocos2d@@QEAAXXZ; cocos2d::CCObject::release(void) ; +0x73, 0x180001453\nlea     rcx, [rbx+88h]                                                 ; +0x79, 0x180001459\ncall    sub_180003700                                                  ; +0x80, 0x180001460\nlea     rcx, [rbx+68h]                                                 ; +0x85, 0x180001465\ncall    sub_180003700                                                  ; +0x89, 0x180001469\nlea     rcx, [rbx+48h]                                                 ; +0x8e, 0x18000146e\ncall    sub_180003700                                                  ; +0x92, 0x180001472\nlea     rcx, [rbx+28h]                                                 ; +0x97, 0x180001477\ncall    sub_180003700                                                  ; +0x9b, 0x18000147b\nlea     rcx, [rbx+8]                                                   ; +0xa0, 0x180001480\ncall    sub_180003700                                                  ; +0xa4, 0x180001484\nnop                                                                    ; +0xa9, 0x180001489\ntest    sil, 1                                                         ; +0xaa, 0x18000148a\njz      short loc_18000149D                                            ; +0xae, 0x18000148e\nmov     edx, 0D0h                                                      ; +0xb0, 0x180001490\nmov     rcx, rbx; Block                                                ; +0xb5, 0x180001495\ncall    j_j_free                                                       ; +0xb8, 0x180001498\nmov     rax, rbx                                                       ; +0xbd, 0x18000149d\nmov     rbx, [rsp+28h+arg_0]                                           ; +0xc0, 0x1800014a0\nmov     rsi, [rsp+28h+arg_8]                                           ; +0xc5, 0x1800014a5\nadd     rsp, 20h                                                       ; +0xca, 0x1800014aa\npop     rdi                                                            ; +0xce, 0x1800014ae\nretn                                                                   ; +0xcf, 0x1800014af", "xrefs": ["<???> @ 0x1800259d8", "<???> @ 0x18004b048"], "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"}