{"type": "func", "start": 5370572848, "end": 5370573014, "name": "EditorUI::onCopyState", "pseudocode": "// \n// EditorUI::onCopyState from 0x1401c7030 to 0x1401c70d6 (166 bytes)\n// \n// 3 xrefs:\n// > EditorUI::handleEditorAction @ 0x1401c4451\n// > EditorUI::init @ 0x1401ab97a\n// > <???> @ 0x14091a78c\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:05 +0000\n// \n\n// Hidden C++ exception states: #wind=1\nvoid __fastcall EditorUI::onCopyState(__int64 a1)\n{\n  _QWORD *v2; // rbx\n  bool hasSoundsForAction; // al\n  __int64 v4; // rcx\n  void *v5; // [rsp+30h] [rbp+8h]\n\n  if ( *(_QWORD *)(a1 + 1568) )\n  {\n    v2 = (_QWORD *)EditorSFXManager::sharedState();\n    hasSoundsForAction = EditorSFXManager::hasSoundsForAction(v2, 112);\n    EditorSFXManager::playAction((__int64)v2, 2 * hasSoundsForAction + 110);\n    v4 = qword_14090BFD0;\n    if ( !qword_14090BFD0 )\n    {\n      v5 = operator new(0x6E8u);\n      qword_14090BFD0 = GameManager::GameManager(v5);\n      (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_14090BFD0 + 72LL))(qword_14090BFD0);\n      v4 = qword_14090BFD0;\n    }\n    LevelEditorLayer::copyObjectState(*(_QWORD *)(v4 + 568), *(_QWORD *)(a1 + 1568));\n    EditorUI::updateButtons(a1);\n  }\n}", "assembly": "; \n; EditorUI::onCopyState from 0x1401c7030 to 0x1401c70d6 (166 bytes)\n; \n; 3 xrefs:\n; > EditorUI::handleEditorAction @ 0x1401c4451\n; > EditorUI::init @ 0x1401ab97a\n; > <???> @ 0x14091a78c\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:05 +0000\n; \nmov     [rsp+arg_8], rbx                                               ; +0x0, 0x1401c7030\npush    rdi                                                            ; +0x5, 0x1401c7035\nsub     rsp, 20h                                                       ; +0x6, 0x1401c7036\nmov     rdi, rcx                                                       ; +0xa, 0x1401c703a\ncmp     qword ptr [rcx+620h], 0                                        ; +0xd, 0x1401c703d\njz      loc_1401C70CB                                                  ; +0x15, 0x1401c7045\ncall    EditorSFXManager__sharedState                                  ; +0x1b, 0x1401c704b\nmov     rbx, rax                                                       ; +0x20, 0x1401c7050\nmov     edx, 70h ; 'p'                                                 ; +0x23, 0x1401c7053\nmov     rcx, rax                                                       ; +0x28, 0x1401c7058\ncall    EditorSFXManager__hasSoundsForAction                           ; +0x2b, 0x1401c705b\nmovzx   edx, al                                                        ; +0x30, 0x1401c7060\nlea     edx, ds:6Eh[rdx*2]                                             ; +0x33, 0x1401c7063\nmov     rcx, rbx                                                       ; +0x3a, 0x1401c706a\ncall    EditorSFXManager__playAction                                   ; +0x3d, 0x1401c706d\nmov     rcx, cs:qword_14090BFD0                                        ; +0x42, 0x1401c7072\ntest    rcx, rcx                                                       ; +0x49, 0x1401c7079\njnz     short loc_1401C70B0                                            ; +0x4c, 0x1401c707c\nmov     ecx, 6E8h; Size                                                ; +0x4e, 0x1401c707e\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0x53, 0x1401c7083\nmov     [rsp+28h+arg_0], rax                                           ; +0x58, 0x1401c7088\nmov     rcx, rax                                                       ; +0x5d, 0x1401c708d\ncall    GameManager__GameManager                                       ; +0x60, 0x1401c7090\nnop                                                                    ; +0x65, 0x1401c7095\nmov     cs:qword_14090BFD0, rax                                        ; +0x66, 0x1401c7096\nmov     rcx, [rax]                                                     ; +0x6d, 0x1401c709d\nmov     rdx, [rcx+48h]                                                 ; +0x70, 0x1401c70a0\nmov     rcx, rax                                                       ; +0x74, 0x1401c70a4\ncall    rdx                                                            ; +0x77, 0x1401c70a7\nmov     rcx, cs:qword_14090BFD0                                        ; +0x79, 0x1401c70a9\nmov     rdx, [rdi+620h]                                                ; +0x80, 0x1401c70b0\nmov     rcx, [rcx+238h]                                                ; +0x87, 0x1401c70b7\ncall    LevelEditorLayer__copyObjectState                              ; +0x8e, 0x1401c70be\nmov     rcx, rdi                                                       ; +0x93, 0x1401c70c3\ncall    EditorUI__updateButtons                                        ; +0x96, 0x1401c70c6\nmov     rbx, [rsp+28h+arg_8]                                           ; +0x9b, 0x1401c70cb\nadd     rsp, 20h                                                       ; +0xa0, 0x1401c70d0\npop     rdi                                                            ; +0xa4, 0x1401c70d4\nretn                                                                   ; +0xa5, 0x1401c70d5", "xrefs": ["EditorUI::handleEditorAction @ 0x1401c4451", "EditorUI::init @ 0x1401ab97a", "<???> @ 0x14091a78c"], "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"}