{"type": "func", "start": 5370815968, "end": 5370816284, "name": "EditorUI::activateRotationControl", "pseudocode": "// \n// EditorUI::activateRotationControl from 0x1402025e0 to 0x14020271c (316 bytes)\n// \n// 11 xrefs:\n// > EditorUI::undoLastAction @ 0x1401b3c0f\n// > EditorUI::redoLastAction @ 0x1401b3c7f\n// > EditorUI::toggleSpecialEditButtons @ 0x1401bb33b\n// > EditorUI::handleEditorAction @ 0x1401c2368\n// > EditorUI::moveObjectCall_1 @ 0x1401fee0a\n// > EditorUI::alignObjects @ 0x140201c8f\n// > EditorUI::updateControlsAfterAlign @ 0x140201d3f\n// > EditorUI::createMoveMenu @ 0x1401f28d7\n// > <???> @ 0x1408a3ec4\n// > <???> @ 0x1408a3ed4\n// > <???> @ 0x14091aee8\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:13 +0000\n// \n\nunsigned int __fastcall EditorUI::activateRotationControl(__int64 a1)\n{\n  unsigned int result; // eax\n  cocos2d::CCArray *v3; // rcx\n  __int64 v4; // rcx\n  cocos2d::CCPoint *GroupCenter; // rax\n  __int64 *v6; // rdi\n  __int64 v7; // rbx\n  __int64 v8; // rax\n  __int64 *v9; // rdi\n  __int64 v10; // rbx\n  __int64 v11; // rdx\n  char v12; // [rsp+30h] [rbp+8h] BYREF\n\n  result = cocos2d::CCArray::count(*(cocos2d::CCArray **)(a1 + 944));\n  if ( result || *(_QWORD *)(a1 + 1568) )\n  {\n    result = (*(__int64 (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 808) + 344LL))(*(_QWORD *)(a1 + 808));\n    if ( !(_BYTE)result || *(_BYTE *)(a1 + 824) )\n    {\n      EditorUI::deactivateTransformControl(a1);\n      v3 = *(cocos2d::CCArray **)(a1 + 944);\n      *(_BYTE *)(a1 + 824) = 0;\n      if ( cocos2d::CCArray::count(v3) )\n      {\n        GroupCenter = EditorUI::getGroupCenter(v4, (cocos2d::CCPoint *)&v12, *(cocos2d::CCArray **)(a1 + 944), 0);\n        cocos2d::CCPoint::operator=(a1 + 816, GroupCenter);\n        (*(void (__fastcall **)(_QWORD, __int64))(**(_QWORD **)(a1 + 808) + 184LL))(*(_QWORD *)(a1 + 808), a1 + 816);\n      }\n      else\n      {\n        v6 = *(__int64 **)(a1 + 808);\n        v7 = *v6;\n        v8 = (*(__int64 (__fastcall **)(_QWORD))(**(_QWORD **)(a1 + 1568) + 200LL))(*(_QWORD *)(a1 + 1568));\n        (*(void (__fastcall **)(__int64 *, __int64))(v7 + 184))(v6, v8);\n      }\n      v9 = *(__int64 **)(a1 + 808);\n      v10 = *v9;\n      (*(void (__fastcall **)(_QWORD))(**(_QWORD **)(*(_QWORD *)(a1 + 1512) + 4296LL) + 168LL))(*(_QWORD *)(*(_QWORD *)(a1 + 1512) + 4296LL));\n      (*(void (__fastcall **)(__int64 *))(v10 + 160))(v9);\n      GJRotationControl::setAngle(*(_QWORD *)(a1 + 808), 0.0);\n      LOBYTE(v11) = 1;\n      return (*(__int64 (__fastcall **)(_QWORD, __int64))(**(_QWORD **)(a1 + 808) + 336LL))(*(_QWORD *)(a1 + 808), v11);\n    }\n  }\n  return result;\n}", "assembly": "; \n; EditorUI::activateRotationControl from 0x1402025e0 to 0x14020271c (316 bytes)\n; \n; 11 xrefs:\n; > EditorUI::undoLastAction @ 0x1401b3c0f\n; > EditorUI::redoLastAction @ 0x1401b3c7f\n; > EditorUI::toggleSpecialEditButtons @ 0x1401bb33b\n; > EditorUI::handleEditorAction @ 0x1401c2368\n; > EditorUI::moveObjectCall_1 @ 0x1401fee0a\n; > EditorUI::alignObjects @ 0x140201c8f\n; > EditorUI::updateControlsAfterAlign @ 0x140201d3f\n; > EditorUI::createMoveMenu @ 0x1401f28d7\n; > <???> @ 0x1408a3ec4\n; > <???> @ 0x1408a3ed4\n; > <???> @ 0x14091aee8\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:13 +0000\n; \nmov     [rsp+arg_10], rbx                                              ; +0x0, 0x1402025e0\npush    rsi                                                            ; +0x5, 0x1402025e5\nsub     rsp, 20h                                                       ; +0x6, 0x1402025e6\nmov     rsi, rcx                                                       ; +0xa, 0x1402025ea\nmov     rcx, [rcx+3B0h]                                                ; +0xd, 0x1402025ed\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x14, 0x1402025f4\ntest    eax, eax                                                       ; +0x1a, 0x1402025fa\njnz     short loc_14020260C                                            ; +0x1c, 0x1402025fc\ncmp     qword ptr [rsi+620h], 0                                        ; +0x1e, 0x1402025fe\njz      loc_140202711                                                  ; +0x26, 0x140202606\nmov     rcx, [rsi+328h]                                                ; +0x2c, 0x14020260c\nmov     rax, [rcx]                                                     ; +0x33, 0x140202613\ncall    qword ptr [rax+158h]                                           ; +0x36, 0x140202616\ntest    al, al                                                         ; +0x3c, 0x14020261c\njz      short loc_14020262D                                            ; +0x3e, 0x14020261e\ncmp     byte ptr [rsi+338h], 0                                         ; +0x40, 0x140202620\njz      loc_140202711                                                  ; +0x47, 0x140202627\nmov     rcx, rsi                                                       ; +0x4d, 0x14020262d\nmov     [rsp+28h+arg_8], rdi                                           ; +0x50, 0x140202630\ncall    EditorUI__deactivateTransformControl                           ; +0x55, 0x140202635\nmov     rcx, [rsi+3B0h]                                                ; +0x5a, 0x14020263a\nmov     byte ptr [rsi+338h], 0                                         ; +0x61, 0x140202641\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x68, 0x140202648\ntest    eax, eax                                                       ; +0x6e, 0x14020264e\njz      short loc_14020268F                                            ; +0x70, 0x140202650\nmov     r8, [rsi+3B0h]                                                 ; +0x72, 0x140202652\nlea     rdx, [rsp+28h+arg_0]                                           ; +0x79, 0x140202659\nxor     r9d, r9d                                                       ; +0x7e, 0x14020265e\ncall    EditorUI__getGroupCenter                                       ; +0x81, 0x140202661\nmov     rdx, rax                                                       ; +0x86, 0x140202666\nlea     rcx, [rsi+330h]                                                ; +0x89, 0x140202669\ncall    cs:??4CCPoint@cocos2d@@QEAAAEAV01@AEBV01@@Z; cocos2d::CCPoint::operator=(cocos2d::CCPoint const &) ; +0x90, 0x140202670\nmov     rcx, [rsi+328h]                                                ; +0x96, 0x140202676\nlea     rdx, [rsi+330h]                                                ; +0x9d, 0x14020267d\nmov     rax, [rcx]                                                     ; +0xa4, 0x140202684\ncall    qword ptr [rax+0B8h]                                           ; +0xa7, 0x140202687\njmp     short loc_1402026B5                                            ; +0xad, 0x14020268d\nmov     rcx, [rsi+620h]                                                ; +0xaf, 0x14020268f\nmov     rdi, [rsi+328h]                                                ; +0xb6, 0x140202696\nmov     rax, [rcx]                                                     ; +0xbd, 0x14020269d\nmov     rbx, [rdi]                                                     ; +0xc0, 0x1402026a0\ncall    qword ptr [rax+0C8h]                                           ; +0xc3, 0x1402026a3\nmov     rdx, rax                                                       ; +0xc9, 0x1402026a9\nmov     rcx, rdi                                                       ; +0xcc, 0x1402026ac\ncall    qword ptr [rbx+0B8h]                                           ; +0xcf, 0x1402026af\nmov     rax, [rsi+5E8h]                                                ; +0xd5, 0x1402026b5\nmov     rdi, [rsi+328h]                                                ; +0xdc, 0x1402026bc\nmov     rcx, [rax+10C8h]                                               ; +0xe3, 0x1402026c3\nmov     rbx, [rdi]                                                     ; +0xea, 0x1402026ca\nmov     rax, [rcx]                                                     ; +0xed, 0x1402026cd\ncall    qword ptr [rax+0A8h]                                           ; +0xf0, 0x1402026d0\nmovss   xmm1, cs:flt_140835080                                         ; +0xf6, 0x1402026d6\nmov     rcx, rdi                                                       ; +0xfe, 0x1402026de\ndivss   xmm1, xmm0                                                     ; +0x101, 0x1402026e1\ncall    qword ptr [rbx+0A0h]                                           ; +0x105, 0x1402026e5\nmov     rcx, [rsi+328h]                                                ; +0x10b, 0x1402026eb\nxorps   xmm1, xmm1                                                     ; +0x112, 0x1402026f2\ncall    GJRotationControl__setAngle                                    ; +0x115, 0x1402026f5\nmov     rcx, [rsi+328h]                                                ; +0x11a, 0x1402026fa\nmov     dl, 1                                                          ; +0x121, 0x140202701\nmov     rax, [rcx]                                                     ; +0x123, 0x140202703\ncall    qword ptr [rax+150h]                                           ; +0x126, 0x140202706\nmov     rdi, [rsp+28h+arg_8]                                           ; +0x12c, 0x14020270c\nmov     rbx, [rsp+28h+arg_10]                                          ; +0x131, 0x140202711\nadd     rsp, 20h                                                       ; +0x136, 0x140202716\npop     rsi                                                            ; +0x13a, 0x14020271a\nretn                                                                   ; +0x13b, 0x14020271b", "xrefs": ["EditorUI::undoLastAction @ 0x1401b3c0f", "EditorUI::redoLastAction @ 0x1401b3c7f", "EditorUI::toggleSpecialEditButtons @ 0x1401bb33b", "EditorUI::handleEditorAction @ 0x1401c2368", "EditorUI::moveObjectCall_1 @ 0x1401fee0a", "EditorUI::alignObjects @ 0x140201c8f", "EditorUI::updateControlsAfterAlign @ 0x140201d3f", "EditorUI::createMoveMenu @ 0x1401f28d7", "<???> @ 0x1408a3ec4", "<???> @ 0x1408a3ed4", "<???> @ 0x14091aee8"], "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"}