{"type": "func", "start": 5369887264, "end": 5369887911, "name": "EditorUI::moveObjectCall_1", "pseudocode": "// \n// EditorUI::moveObjectCall_1 from 0x14011fa20 to 0x14011fca7 (647 bytes)\n// \n// 6 xrefs:\n// > EditorUI::moveObjectCall @ 0x14011fa0c\n// > EditorUI::keyDown @ 0x1401254e2\n// > EditorUI::keyDown @ 0x140125b56\n// > EditorUI::keyDown @ 0x140125b91\n// > EditorUI::keyDown @ 0x140125bca\n// > <???> @ 0x1406c95b8\n// \n// This function is hookable on this platform!\n// \n// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings\n// \n\n// Hidden C++ exception states: #wind=2\nvoid EditorUI::moveObjectCall_1(EditorUI *a1, EditCommand a2)\n{\n  GameObject **p_m_selectedObject; // r15\n  UndoCommand v4; // edx\n  unsigned int i; // esi\n  GameObject *v6; // rbx\n  cocos2d::CCPoint v7; // rax\n  GameObject *m_selectedObject; // rbx\n  cocos2d::CCObject *v9; // r14\n  GameObject **v10; // r12\n  GameObjectCopy *v11; // rax\n  LevelEditorLayer *m_editorLayer; // rsi\n  bool m_increaseMaxUndoRedo; // bl\n  GameObject **v14; // rbp\n  unsigned int v15; // eax\n  unsigned int v16; // ecx\n  cocos2d::CCPoint v17; // rax\n  const cocos2d::CCPoint *v18; // rax\n  struct cocos2d::CCPoint v19; // [rsp+50h] [rbp+8h] BYREF\n  cocos2d::CCObject *v20; // [rsp+60h] [rbp+18h] BYREF\n\n  if ( a1->m_selectedObject )\n  {\n    p_m_selectedObject = &a1->m_selectedObject;\n  }\n  else\n  {\n    if ( !cocos2d::CCArray::count(a1->m_selectedObjects) )\n      return;\n    p_m_selectedObject = &a1->m_selectedObject;\n  }\n  EditorUI::moveForCommand(a1, (EditCommand)&v19);\n  if ( cocos2d::CCArray::count(a1->m_selectedObjects) )\n  {\n    EditorUI::createUndoObject(a1, v4, 0);\n    for ( i = 0; i < cocos2d::CCArray::count(a1->m_selectedObjects); ++i )\n    {\n      v6 = (GameObject *)cocos2d::CCArray::objectAtIndex(a1->m_selectedObjects, i);\n      cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v20, &v19);\n      EditorUI::moveObject(a1, v6, v7);\n    }\n  }\n  else\n  {\n    m_selectedObject = a1->m_selectedObject;\n    v9 = (cocos2d::CCObject *)operator new(0xA0u);\n    v20 = v9;\n    cocos2d::CCObject::CCObject(v9);\n    v9->__vftable = (cocos2d::CCObject_vtbl *)&UndoObject::`vftable';\n    v9[1].__vftable = nullptr;\n    v9[1].m_uID = 0;\n    *(_QWORD *)&v9[1].m_nTag = 0;\n    LOWORD(v9[1].m_uAutoReleaseCount) = 0;\n    sub_1400DE960((__int64)&v9[1].m_eObjType);\n    v10 = p_m_selectedObject;\n    if ( m_selectedObject )\n    {\n      v11 = GameObjectCopy::create(m_selectedObject);\n      v9[1].__vftable = (cocos2d::CCObject_vtbl *)v11;\n      cocos2d::CCObject::retain(v11);\n      v10 = &a1->m_selectedObject;\n    }\n    v9[1].m_uID = 5;\n    cocos2d::CCObject::autorelease(v9);\n    m_editorLayer = a1->m_editorLayer;\n    cocos2d::CCArray::removeAllObjects(m_editorLayer->m_redoObjects);\n    m_increaseMaxUndoRedo = m_editorLayer->m_increaseMaxUndoRedo;\n    v14 = p_m_selectedObject;\n    if ( m_increaseMaxUndoRedo )\n      v14 = v10;\n    v15 = cocos2d::CCArray::count(m_editorLayer->m_undoObjects);\n    v16 = 1000;\n    if ( !m_increaseMaxUndoRedo )\n      v16 = 200;\n    if ( v15 >= v16 )\n    {\n      cocos2d::CCArray::removeObjectAtIndex(m_editorLayer->m_undoObjects, 0, 1);\n      p_m_selectedObject = v14;\n    }\n    cocos2d::CCArray::addObject(m_editorLayer->m_undoObjects, v9);\n    cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v20, &v19);\n    EditorUI::moveObject(a1, *p_m_selectedObject, v17);\n  }\n  if ( a1->m_transformControl->isVisible(a1->m_transformControl) )\n  {\n    v18 = a1->m_transformControl->getPosition_0(a1->m_transformControl);\n    cocos2d::CCPoint::operator+(v18, &v20);\n    a1->m_transformControl->setPosition_0(a1->m_transformControl, (const cocos2d::CCPoint *)&v20);\n    GJTransformControl::refreshControl(a1->m_transformControl);\n  }\n  if ( a1->m_rotationControl->isVisible(a1->m_rotationControl) )\n  {\n    a1->m_canActivateControls = 1;\n    EditorUI::activateRotationControl(a1, nullptr);\n  }\n  a1->updateScaleControl(&a1->GJScaleControlDelegate);\n  EditorUI::updateButtons(a1);\n}", "assembly": "; \n; EditorUI::moveObjectCall_1 from 0x14011fa20 to 0x14011fca7 (647 bytes)\n; \n; 6 xrefs:\n; > EditorUI::moveObjectCall @ 0x14011fa0c\n; > EditorUI::keyDown @ 0x1401254e2\n; > EditorUI::keyDown @ 0x140125b56\n; > EditorUI::keyDown @ 0x140125b91\n; > EditorUI::keyDown @ 0x140125bca\n; > <???> @ 0x1406c95b8\n; \n; This function is hookable on this platform!\n; \n; Using BromaIDA 8.0.0 @ https:;github.com/Stazzical/BromaIDA\n; Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https:;github.com/geode-sdk/bindings\n; \n\nmov     [rsp+arg_8], rbx                                               ; +0x0, 0x14011fa20\nmov     [rsp+arg_18], rbp                                              ; +0x5, 0x14011fa25\npush    rsi                                                            ; +0xa, 0x14011fa2a\npush    rdi                                                            ; +0xb, 0x14011fa2b\npush    r12                                                            ; +0xc, 0x14011fa2c\npush    r14                                                            ; +0xe, 0x14011fa2e\npush    r15                                                            ; +0x10, 0x14011fa30\nsub     rsp, 20h                                                       ; +0x12, 0x14011fa32\nmov     esi, edx                                                       ; +0x16, 0x14011fa36\nmov     rdi, rcx                                                       ; +0x18, 0x14011fa38\ncmp     qword ptr [rcx+538h], 0                                        ; +0x1b, 0x14011fa3b\njnz     short loc_14011FA63                                            ; +0x23, 0x14011fa43\nmov     rcx, [rcx+340h]                                                ; +0x25, 0x14011fa45\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x2c, 0x14011fa4c\ntest    eax, eax                                                       ; +0x32, 0x14011fa52\njz      loc_14011FC90                                                  ; +0x34, 0x14011fa54\nlea     r15, [rdi+538h]                                                ; +0x3a, 0x14011fa5a\njmp     short loc_14011FA6A                                            ; +0x41, 0x14011fa61\nlea     r15, [rcx+538h]                                                ; +0x43, 0x14011fa63\nmov     r8d, esi                                                       ; +0x4a, 0x14011fa6a\nlea     rdx, [rsp+48h+arg_0]                                           ; +0x4d, 0x14011fa6d\nmov     rcx, rdi                                                       ; +0x52, 0x14011fa72\ncall    EditorUI__moveForCommand                                       ; +0x55, 0x14011fa75\nmov     rcx, [rdi+340h]                                                ; +0x5a, 0x14011fa7a\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x61, 0x14011fa81\ntest    eax, eax                                                       ; +0x67, 0x14011fa87\njz      short loc_14011FAF8                                            ; +0x69, 0x14011fa89\nxor     r8d, r8d                                                       ; +0x6b, 0x14011fa8b\nmov     rcx, rdi                                                       ; +0x6e, 0x14011fa8e\ncall    EditorUI__createUndoObject                                     ; +0x71, 0x14011fa91\nxor     esi, esi                                                       ; +0x76, 0x14011fa96\nmov     rcx, [rdi+340h]                                                ; +0x78, 0x14011fa98\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x7f, 0x14011fa9f\ntest    eax, eax                                                       ; +0x85, 0x14011faa5\njz      loc_14011FBFE                                                  ; +0x87, 0x14011faa7\nnop     dword ptr [rax]                                                ; +0x8d, 0x14011faad\nmov     edx, esi                                                       ; +0x90, 0x14011fab0\nmov     rcx, [rdi+340h]                                                ; +0x92, 0x14011fab2\ncall    cs:?objectAtIndex@CCArray@cocos2d@@QEAAPEAVCCObject@2@I@Z; cocos2d::CCArray::objectAtIndex(uint) ; +0x99, 0x14011fab9\nmov     rbx, rax                                                       ; +0x9f, 0x14011fabf\nlea     rdx, [rsp+48h+arg_0]                                           ; +0xa2, 0x14011fac2\nlea     rcx, [rsp+48h+arg_10]                                          ; +0xa7, 0x14011fac7\ncall    cs:??0CCPoint@cocos2d@@QEAA@AEBV01@@Z; cocos2d::CCPoint::CCPoint(cocos2d::CCPoint const &) ; +0xac, 0x14011facc\nmov     r8, rax                                                        ; +0xb2, 0x14011fad2\nmov     rdx, rbx                                                       ; +0xb5, 0x14011fad5\nmov     rcx, rdi                                                       ; +0xb8, 0x14011fad8\ncall    EditorUI__moveObject                                           ; +0xbb, 0x14011fadb\ninc     esi                                                            ; +0xc0, 0x14011fae0\nmov     rcx, [rdi+340h]                                                ; +0xc2, 0x14011fae2\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0xc9, 0x14011fae9\ncmp     esi, eax                                                       ; +0xcf, 0x14011faef\njb      short loc_14011FAB0                                            ; +0xd1, 0x14011faf1\njmp     loc_14011FBFE                                                  ; +0xd3, 0x14011faf3\nmov     rbx, [rdi+538h]                                                ; +0xd8, 0x14011faf8\nmov     ecx, 0A0h; Size                                                ; +0xdf, 0x14011faff\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0xe4, 0x14011fb04\nmov     r14, rax                                                       ; +0xe9, 0x14011fb09\nmov     [rsp+48h+arg_10], rax                                          ; +0xec, 0x14011fb0c\nmov     rcx, rax                                                       ; +0xf1, 0x14011fb11\ncall    cs:??0CCObject@cocos2d@@QEAA@XZ; cocos2d::CCObject::CCObject(void) ; +0xf4, 0x14011fb14\nnop                                                                    ; +0xfa, 0x14011fb1a\nlea     rax, ??_7UndoObject@@6B@; const UndoObject::`vftable'          ; +0xfb, 0x14011fb1b\nmov     [r14], rax                                                     ; +0x102, 0x14011fb22\nxor     esi, esi                                                       ; +0x105, 0x14011fb25\nmov     [r14+38h], rsi                                                 ; +0x107, 0x14011fb27\nmov     [r14+40h], esi                                                 ; +0x10b, 0x14011fb2b\nmov     [r14+48h], rsi                                                 ; +0x10f, 0x14011fb2f\nmov     [r14+50h], si                                                  ; +0x113, 0x14011fb33\nlea     rcx, [r14+54h]                                                 ; +0x118, 0x14011fb38\ncall    sub_1400DE960                                                  ; +0x11c, 0x14011fb3c\nnop                                                                    ; +0x121, 0x14011fb41\nmov     r12, r15                                                       ; +0x122, 0x14011fb42\ntest    rbx, rbx                                                       ; +0x125, 0x14011fb45\njz      short loc_14011FB66                                            ; +0x128, 0x14011fb48\nmov     rcx, rbx                                                       ; +0x12a, 0x14011fb4a\ncall    GameObjectCopy__create                                         ; +0x12d, 0x14011fb4d\nmov     [r14+38h], rax                                                 ; +0x132, 0x14011fb52\nmov     rcx, rax                                                       ; +0x136, 0x14011fb56\ncall    cs:?retain@CCObject@cocos2d@@QEAAXXZ; cocos2d::CCObject::retain(void) ; +0x139, 0x14011fb59\nlea     r12, [rdi+538h]                                                ; +0x13f, 0x14011fb5f\nmov     dword ptr [r14+40h], 5                                         ; +0x146, 0x14011fb66\nmov     rcx, r14                                                       ; +0x14e, 0x14011fb6e\ncall    cs:?autorelease@CCObject@cocos2d@@QEAAPEAV12@XZ; cocos2d::CCObject::autorelease(void) ; +0x151, 0x14011fb71\nmov     rsi, [rdi+500h]                                                ; +0x157, 0x14011fb77\nmov     rcx, [rsi+38B0h]                                               ; +0x15e, 0x14011fb7e\ncall    cs:?removeAllObjects@CCArray@cocos2d@@QEAAXXZ; cocos2d::CCArray::removeAllObjects(void) ; +0x165, 0x14011fb85\nmovzx   ebx, byte ptr [rsi+37AEh]                                      ; +0x16b, 0x14011fb8b\nmov     rbp, r15                                                       ; +0x172, 0x14011fb92\ntest    bl, bl                                                         ; +0x175, 0x14011fb95\ncmovnz  rbp, r12                                                       ; +0x177, 0x14011fb97\nmov     rcx, [rsi+38A8h]                                               ; +0x17b, 0x14011fb9b\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x182, 0x14011fba2\nmov     ecx, 3E8h                                                      ; +0x188, 0x14011fba8\nmov     edx, 0C8h                                                      ; +0x18d, 0x14011fbad\ntest    bl, bl                                                         ; +0x192, 0x14011fbb2\ncmovz   ecx, edx                                                       ; +0x194, 0x14011fbb4\ncmp     eax, ecx                                                       ; +0x197, 0x14011fbb7\njb      short loc_14011FBD0                                            ; +0x199, 0x14011fbb9\nmov     r8b, 1                                                         ; +0x19b, 0x14011fbbb\nxor     edx, edx                                                       ; +0x19e, 0x14011fbbe\nmov     rcx, [rsi+38A8h]                                               ; +0x1a0, 0x14011fbc0\ncall    cs:?removeObjectAtIndex@CCArray@cocos2d@@QEAAXI_N@Z; cocos2d::CCArray::removeObjectAtIndex(uint,bool) ; +0x1a7, 0x14011fbc7\nmov     r15, rbp                                                       ; +0x1ad, 0x14011fbcd\nmov     rdx, r14                                                       ; +0x1b0, 0x14011fbd0\nmov     rcx, [rsi+38A8h]                                               ; +0x1b3, 0x14011fbd3\ncall    cs:?addObject@CCArray@cocos2d@@QEAAXPEAVCCObject@2@@Z; cocos2d::CCArray::addObject(cocos2d::CCObject *) ; +0x1ba, 0x14011fbda\nlea     rdx, [rsp+48h+arg_0]                                           ; +0x1c0, 0x14011fbe0\nlea     rcx, [rsp+48h+arg_10]                                          ; +0x1c5, 0x14011fbe5\ncall    cs:??0CCPoint@cocos2d@@QEAA@AEBV01@@Z; cocos2d::CCPoint::CCPoint(cocos2d::CCPoint const &) ; +0x1ca, 0x14011fbea\nmov     r8, rax                                                        ; +0x1d0, 0x14011fbf0\nmov     rdx, [r15]                                                     ; +0x1d3, 0x14011fbf3\nmov     rcx, rdi                                                       ; +0x1d6, 0x14011fbf6\ncall    EditorUI__moveObject                                           ; +0x1d9, 0x14011fbf9\nmov     rcx, [rdi+2D8h]                                                ; +0x1de, 0x14011fbfe\nmov     rax, [rcx]                                                     ; +0x1e5, 0x14011fc05\ncall    qword ptr [rax+148h]                                           ; +0x1e8, 0x14011fc08\ntest    al, al                                                         ; +0x1ee, 0x14011fc0e\njz      short loc_14011FC56                                            ; +0x1f0, 0x14011fc10\nmov     rcx, [rdi+2D8h]                                                ; +0x1f2, 0x14011fc12\nmov     rax, [rcx]                                                     ; +0x1f9, 0x14011fc19\ncall    qword ptr [rax+0C8h]                                           ; +0x1fc, 0x14011fc1c\nlea     r8, [rsp+48h+arg_0]                                            ; +0x202, 0x14011fc22\nlea     rdx, [rsp+48h+arg_10]                                          ; +0x207, 0x14011fc27\nmov     rcx, rax                                                       ; +0x20c, 0x14011fc2c\ncall    cs:??HCCPoint@cocos2d@@QEBA?AV01@AEBV01@@Z; cocos2d::CCPoint::operator+(cocos2d::CCPoint const &) ; +0x20f, 0x14011fc2f\nmov     rcx, [rdi+2D8h]                                                ; +0x215, 0x14011fc35\nmov     rax, [rcx]                                                     ; +0x21c, 0x14011fc3c\nlea     rdx, [rsp+48h+arg_10]                                          ; +0x21f, 0x14011fc3f\ncall    qword ptr [rax+0B8h]                                           ; +0x224, 0x14011fc44\nmov     rcx, [rdi+2D8h]                                                ; +0x22a, 0x14011fc4a\ncall    GJTransformControl__refreshControl                             ; +0x231, 0x14011fc51\nmov     rcx, [rdi+2B8h]                                                ; +0x236, 0x14011fc56\nmov     rax, [rcx]                                                     ; +0x23d, 0x14011fc5d\ncall    qword ptr [rax+148h]                                           ; +0x240, 0x14011fc60\ntest    al, al                                                         ; +0x246, 0x14011fc66\njz      short loc_14011FC7B                                            ; +0x248, 0x14011fc68\nmov     byte ptr [rdi+2C8h], 1                                         ; +0x24a, 0x14011fc6a\nxor     edx, edx                                                       ; +0x251, 0x14011fc71\nmov     rcx, rdi                                                       ; +0x253, 0x14011fc73\ncall    EditorUI__activateRotationControl                              ; +0x256, 0x14011fc76\nlea     rcx, [rdi+1B0h]                                                ; +0x25b, 0x14011fc7b\nmov     rax, [rcx]                                                     ; +0x262, 0x14011fc82\ncall    qword ptr [rax+28h]                                            ; +0x265, 0x14011fc85\nmov     rcx, rdi                                                       ; +0x268, 0x14011fc88\ncall    EditorUI__updateButtons                                        ; +0x26b, 0x14011fc8b\nmov     rbx, [rsp+48h+arg_8]                                           ; +0x270, 0x14011fc90\nmov     rbp, [rsp+48h+arg_18]                                          ; +0x275, 0x14011fc95\nadd     rsp, 20h                                                       ; +0x27a, 0x14011fc9a\npop     r15                                                            ; +0x27e, 0x14011fc9e\npop     r14                                                            ; +0x280, 0x14011fca0\npop     r12                                                            ; +0x282, 0x14011fca2\npop     rdi                                                            ; +0x284, 0x14011fca4\npop     rsi                                                            ; +0x285, 0x14011fca5\nretn                                                                   ; +0x286, 0x14011fca6", "xrefs": ["EditorUI::moveObjectCall @ 0x14011fa0c", "EditorUI::keyDown @ 0x1401254e2", "EditorUI::keyDown @ 0x140125b56", "EditorUI::keyDown @ 0x140125b91", "EditorUI::keyDown @ 0x140125bca", "<???> @ 0x1406c95b8"], "is_objc": false, "is_arm32": false, "is_arm64": false, "bida_info": "8.0.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings"}