{"type": "func", "start": 4296911984, "end": 4296912322, "name": "CustomizeObjectLayer::recreateLayer", "pseudocode": "// \n// CustomizeObjectLayer::recreateLayer from 0x1001dac70 to 0x1001dadc2 (338 bytes)\n// \n// 1 xrefs:\n// > CustomizeObjectSettingsPopup::onClose @ 0x1001dc0f0\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:26 +0000\n// \n\n__int64 __fastcall CustomizeObjectLayer::recreateLayer(__int64 a1, __int64 a2)\n{\n  __int64 v2; // r15\n  __int64 v3; // r14\n  __int64 v4; // rbx\n  __int64 v5; // rax\n  __int64 v6; // rax\n  _QWORD *v7; // rdi\n  __int64 v8; // rdx\n  __int64 v9; // rdi\n  __int64 v10; // rax\n  __int64 v11; // rdx\n  double v12; // xmm0_8\n  __int64 v13; // rax\n  __int64 v14; // rdx\n  void *v15; // r15\n  __int64 result; // rax\n\n  v2 = a1;\n  v3 = *(_QWORD *)(a1 + 688);\n  v4 = *(_QWORD *)(a1 + 696);\n  if ( v3 )\n  {\n    a1 = *(_QWORD *)(a1 + 688);\n    cocos2d::CCObject::retain(a1);\n  }\n  if ( v4 )\n  {\n    a1 = v4;\n    cocos2d::CCObject::retain(v4);\n  }\n  v5 = cocos2d::CCDirector::sharedDirector(a1, a2);\n  v6 = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v5 + 160LL))(v5);\n  cocos2d::CCTouchDispatcher::unregisterForcePrio(v6, v2);\n  v7 = *(_QWORD **)(v2 + 816);\n  v7[73] = 0;\n  (*(void (__fastcall **)(_QWORD *, _QWORD))(*v7 + 1160LL))(v7, 0);\n  v9 = *(_QWORD *)(v2 + 824);\n  if ( v9 )\n  {\n    (*(void (__fastcall **)(__int64, _QWORD))(*(_QWORD *)v9 + 1160LL))(v9, 0);\n    *(_QWORD *)(*(_QWORD *)(v2 + 824) + 584LL) = 0;\n  }\n  GameManager::sharedState(v9, 0, v8);\n  *(_DWORD *)(v10 + 972) = *(_DWORD *)(v2 + 748);\n  *(_QWORD *)&v12 = GameManager::sharedState(v9, 0, v11).u64[0];\n  EditorUI::updateObjectInfoLabel(*(_QWORD *)(*(_QWORD *)(v13 + 552) + 14248LL), 0, v14);\n  (*(void (__fastcall **)(__int64, _QWORD, double))(*(_QWORD *)v2 + 1072LL))(v2, 0, v12);\n  (*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)v2 + 528LL))(v2, 1);\n  v15 = operator new(0x3A0u);\n  CustomizeObjectLayer::CustomizeObjectLayer(v15);\n  if ( !(unsigned __int8)CustomizeObjectLayer::init((__int64)v15, v3, v4) )\n    sub_1009A64E0(v15);\n  cocos2d::CCObject::autorelease(v15);\n  result = (*(__int64 (__fastcall **)(void *))(*(_QWORD *)v15 + 1312LL))(v15);\n  if ( v3 )\n    result = cocos2d::CCObject::release(v3);\n  if ( v4 )\n    return cocos2d::CCObject::release(v4);\n  return result;\n}", "assembly": "; \n; CustomizeObjectLayer::recreateLayer from 0x1001dac70 to 0x1001dadc2 (338 bytes)\n; \n; 1 xrefs:\n; > CustomizeObjectSettingsPopup::onClose @ 0x1001dc0f0\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:26 +0000\n; \npush    rbp                                                            ; +0x0, 0x1001dac70\nmov     rbp, rsp                                                       ; +0x1, 0x1001dac71\npush    r15                                                            ; +0x4, 0x1001dac74\npush    r14                                                            ; +0x6, 0x1001dac76\npush    rbx                                                            ; +0x8, 0x1001dac78\npush    rax                                                            ; +0x9, 0x1001dac79\nmov     r15, rdi                                                       ; +0xa, 0x1001dac7a\nmov     r14, [rdi+2B0h]                                                ; +0xd, 0x1001dac7d\nmov     rbx, [rdi+2B8h]                                                ; +0x14, 0x1001dac84\ntest    r14, r14                                                       ; +0x1b, 0x1001dac8b\njz      short loc_1001DAC98                                            ; +0x1e, 0x1001dac8e\nmov     rdi, r14                                                       ; +0x20, 0x1001dac90\ncall    cocos2d__CCObject__retain                                      ; +0x23, 0x1001dac93\ntest    rbx, rbx                                                       ; +0x28, 0x1001dac98\njz      short loc_1001DACA5                                            ; +0x2b, 0x1001dac9b\nmov     rdi, rbx                                                       ; +0x2d, 0x1001dac9d\ncall    cocos2d__CCObject__retain                                      ; +0x30, 0x1001daca0\ncall    cocos2d__CCDirector__sharedDirector                            ; +0x35, 0x1001daca5\nmov     rcx, [rax]                                                     ; +0x3a, 0x1001dacaa\nmov     rdi, rax                                                       ; +0x3d, 0x1001dacad\ncall    qword ptr [rcx+0A0h]                                           ; +0x40, 0x1001dacb0\nmov     rdi, rax                                                       ; +0x46, 0x1001dacb6\nmov     rsi, r15                                                       ; +0x49, 0x1001dacb9\ncall    cocos2d__CCTouchDispatcher__unregisterForcePrio                ; +0x4c, 0x1001dacbc\nmov     rdi, [r15+330h]                                                ; +0x51, 0x1001dacc1\nmov     qword ptr [rdi+248h], 0                                        ; +0x58, 0x1001dacc8\nmov     rax, [rdi]                                                     ; +0x63, 0x1001dacd3\nxor     esi, esi                                                       ; +0x66, 0x1001dacd6\ncall    qword ptr [rax+488h]                                           ; +0x68, 0x1001dacd8\nmov     rdi, [r15+338h]                                                ; +0x6e, 0x1001dacde\ntest    rdi, rdi                                                       ; +0x75, 0x1001dace5\njz      short loc_1001DAD07                                            ; +0x78, 0x1001dace8\nmov     rax, [rdi]                                                     ; +0x7a, 0x1001dacea\nxor     esi, esi                                                       ; +0x7d, 0x1001daced\ncall    qword ptr [rax+488h]                                           ; +0x7f, 0x1001dacef\nmov     rax, [r15+338h]                                                ; +0x85, 0x1001dacf5\nmov     qword ptr [rax+248h], 0                                        ; +0x8c, 0x1001dacfc\ncall    GameManager__sharedState                                       ; +0x97, 0x1001dad07\nmov     ecx, [r15+2ECh]                                                ; +0x9c, 0x1001dad0c\nmov     [rax+3CCh], ecx                                                ; +0xa3, 0x1001dad13\ncall    GameManager__sharedState                                       ; +0xa9, 0x1001dad19\nmov     rax, [rax+228h]                                                ; +0xae, 0x1001dad1e\nmov     rdi, [rax+37A8h]                                               ; +0xb5, 0x1001dad25\ncall    EditorUI__updateObjectInfoLabel                                ; +0xbc, 0x1001dad2c\nmov     rax, [r15]                                                     ; +0xc1, 0x1001dad31\nmov     rdi, r15                                                       ; +0xc4, 0x1001dad34\nxor     esi, esi                                                       ; +0xc7, 0x1001dad37\ncall    qword ptr [rax+430h]                                           ; +0xc9, 0x1001dad39\nmov     rax, [r15]                                                     ; +0xcf, 0x1001dad3f\nmov     rdi, r15                                                       ; +0xd2, 0x1001dad42\nmov     esi, 1                                                         ; +0xd5, 0x1001dad45\ncall    qword ptr [rax+210h]                                           ; +0xda, 0x1001dad4a\nmov     edi, 3A0h; __sz                                                ; +0xe0, 0x1001dad50\ncall    __Znwm; operator new(ulong)                                    ; +0xe5, 0x1001dad55\nmov     r15, rax                                                       ; +0xea, 0x1001dad5a\nmov     rdi, rax                                                       ; +0xed, 0x1001dad5d\ncall    CustomizeObjectLayer__CustomizeObjectLayer                     ; +0xf0, 0x1001dad60\nmov     rdi, r15                                                       ; +0xf5, 0x1001dad65\nmov     rsi, r14                                                       ; +0xf8, 0x1001dad68\nmov     rdx, rbx                                                       ; +0xfb, 0x1001dad6b\ncall    CustomizeObjectLayer__init                                     ; +0xfe, 0x1001dad6e\ntest    al, al                                                         ; +0x103, 0x1001dad73\njz      short loc_1001DADBA                                            ; +0x105, 0x1001dad75\nmov     rdi, r15                                                       ; +0x107, 0x1001dad77\ncall    cocos2d__CCObject__autorelease                                 ; +0x10a, 0x1001dad7a\nmov     rax, [r15]                                                     ; +0x10f, 0x1001dad7f\nmov     rdi, r15                                                       ; +0x112, 0x1001dad82\ncall    qword ptr [rax+520h]                                           ; +0x115, 0x1001dad85\ntest    r14, r14                                                       ; +0x11b, 0x1001dad8b\njz      short loc_1001DAD98                                            ; +0x11e, 0x1001dad8e\nmov     rdi, r14                                                       ; +0x120, 0x1001dad90\ncall    cocos2d__CCObject__release                                     ; +0x123, 0x1001dad93\ntest    rbx, rbx                                                       ; +0x128, 0x1001dad98\njz      short loc_1001DADAF                                            ; +0x12b, 0x1001dad9b\nmov     rdi, rbx                                                       ; +0x12d, 0x1001dad9d\nadd     rsp, 8                                                         ; +0x130, 0x1001dada0\npop     rbx                                                            ; +0x134, 0x1001dada4\npop     r14                                                            ; +0x135, 0x1001dada5\npop     r15                                                            ; +0x137, 0x1001dada7\npop     rbp                                                            ; +0x139, 0x1001dada9\njmp     cocos2d__CCObject__release                                     ; +0x13a, 0x1001dadaa\nadd     rsp, 8                                                         ; +0x13f, 0x1001dadaf\npop     rbx                                                            ; +0x143, 0x1001dadb3\npop     r14                                                            ; +0x144, 0x1001dadb4\npop     r15                                                            ; +0x146, 0x1001dadb6\npop     rbp                                                            ; +0x148, 0x1001dadb8\nretn                                                                   ; +0x149, 0x1001dadb9\nmov     rdi, r15                                                       ; +0x14a, 0x1001dadba\ncall    sub_1009A64E0                                                  ; +0x14d, 0x1001dadbd", "xrefs": ["CustomizeObjectSettingsPopup::onClose @ 0x1001dc0f0"], "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"}