{"type": "func", "start": 4295215504, "end": 4295215739, "name": "EditorUI::editHSV", "pseudocode": "// \n// EditorUI::editHSV from 0x10003c990 to 0x10003ca7b (235 bytes)\n// \n// 2 xrefs:\n// > EditorUI::onEditColor @ 0x10002ae58\n// > EditorUI::checkLiveColorSelect @ 0x10003c734\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\nvoid __fastcall EditorUI::editHSV(EditorUI *a1)\n{\n  HSVLiveOverlay *m_hsvOverlay; // rdi\n  ColorSelectLiveOverlay *m_colorOverlay; // rdi\n  GameObject *m_selectedObject; // rdi\n  cocos2d::CCArray *SelectedObjects; // r14\n  HSVLiveOverlay *v6; // rax\n  cocos2d::CCArray *m_selectedObjects; // rax\n  cocos2d::ccArray *data; // rax\n  GameObject **arr; // r15\n  unsigned __int64 v10; // r12\n\n  m_hsvOverlay = a1->m_hsvOverlay;\n  if ( m_hsvOverlay )\n  {\n    HSVLiveOverlay::closeColorSelect(m_hsvOverlay, nullptr);\n    a1->m_hsvOverlay = nullptr;\n  }\n  m_colorOverlay = a1->m_colorOverlay;\n  if ( m_colorOverlay )\n  {\n    ColorSelectLiveOverlay::closeColorSelect(m_colorOverlay, nullptr);\n    a1->m_colorOverlay = nullptr;\n  }\n  m_selectedObject = a1->m_selectedObject;\n  if ( m_selectedObject )\n  {\n    GameObject::deselectObject(m_selectedObject);\n    SelectedObjects = nullptr;\n  }\n  else\n  {\n    SelectedObjects = EditorUI::getSelectedObjects(a1);\n    m_selectedObjects = a1->m_selectedObjects;\n    if ( m_selectedObjects )\n    {\n      data = m_selectedObjects->data;\n      if ( data->num )\n      {\n        arr = (GameObject **)data->arr;\n        v10 = (unsigned __int64)&arr[data->num - 1];\n        do\n        {\n          if ( !*arr )\n            break;\n          GameObject::deselectObject(*arr++);\n        }\n        while ( (unsigned __int64)arr <= v10 );\n      }\n    }\n  }\n  v6 = HSVLiveOverlay::create(a1->m_selectedObject, SelectedObjects);\n  a1->m_hsvOverlay = v6;\n  v6->m_delegate = &a1->ColorSelectDelegate;\n  v6->m_scene = a1;\n  ((void (__fastcall *)(HSVLiveOverlay *))v6->show)(v6);\n}", "assembly": "; \n; EditorUI::editHSV from 0x10003c990 to 0x10003ca7b (235 bytes)\n; \n; 2 xrefs:\n; > EditorUI::onEditColor @ 0x10002ae58\n; > EditorUI::checkLiveColorSelect @ 0x10003c734\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\npush    rbp                                                            ; +0x0, 0x10003c990\nmov     rbp, rsp                                                       ; +0x1, 0x10003c991\npush    r15                                                            ; +0x4, 0x10003c994\npush    r14                                                            ; +0x6, 0x10003c996\npush    r12                                                            ; +0x8, 0x10003c998\npush    rbx                                                            ; +0xa, 0x10003c99a\nmov     rbx, rdi                                                       ; +0xb, 0x10003c99b\nmov     rdi, [rdi+550h]                                                ; +0xe, 0x10003c99e\ntest    rdi, rdi                                                       ; +0x15, 0x10003c9a5\njz      short loc_10003C9BC                                            ; +0x18, 0x10003c9a8\nxor     esi, esi                                                       ; +0x1a, 0x10003c9aa\ncall    HSVLiveOverlay__closeColorSelect                               ; +0x1c, 0x10003c9ac\nmov     qword ptr [rbx+550h], 0                                        ; +0x21, 0x10003c9b1\nmov     rdi, [rbx+548h]                                                ; +0x2c, 0x10003c9bc\ntest    rdi, rdi                                                       ; +0x33, 0x10003c9c3\njz      short loc_10003C9DA                                            ; +0x36, 0x10003c9c6\nxor     esi, esi                                                       ; +0x38, 0x10003c9c8\ncall    ColorSelectLiveOverlay__closeColorSelect                       ; +0x3a, 0x10003c9ca\nmov     qword ptr [rbx+548h], 0                                        ; +0x3f, 0x10003c9cf\nmov     rdi, [rbx+520h]                                                ; +0x4a, 0x10003c9da\ntest    rdi, rdi                                                       ; +0x51, 0x10003c9e1\njz      short loc_10003CA2D                                            ; +0x54, 0x10003c9e4\ncall    GameObject__deselectObject                                     ; +0x56, 0x10003c9e6\nxor     r14d, r14d                                                     ; +0x5b, 0x10003c9eb\nmov     rdi, [rbx+520h]                                                ; +0x5e, 0x10003c9ee\nmov     rsi, r14                                                       ; +0x65, 0x10003c9f5\ncall    HSVLiveOverlay__create                                         ; +0x68, 0x10003c9f8\nmov     [rbx+550h], rax                                                ; +0x6d, 0x10003c9fd\nlea     rcx, [rbx+1A0h]                                                ; +0x74, 0x10003ca04\nmov     [rax+2A0h], rcx                                                ; +0x7b, 0x10003ca0b\nmov     [rax+230h], rbx                                                ; +0x82, 0x10003ca12\nmov     rcx, [rax]                                                     ; +0x89, 0x10003ca19\nmov     rdi, rax                                                       ; +0x8c, 0x10003ca1c\npop     rbx                                                            ; +0x8f, 0x10003ca1f\npop     r12                                                            ; +0x90, 0x10003ca20\npop     r14                                                            ; +0x92, 0x10003ca22\npop     r15                                                            ; +0x94, 0x10003ca24\npop     rbp                                                            ; +0x96, 0x10003ca26\njmp     qword ptr [rcx+508h]                                           ; +0x97, 0x10003ca27\nmov     rdi, rbx                                                       ; +0x9d, 0x10003ca2d\ncall    EditorUI__getSelectedObjects                                   ; +0xa0, 0x10003ca30\nmov     r14, rax                                                       ; +0xa5, 0x10003ca35\nmov     rax, [rbx+328h]                                                ; +0xa8, 0x10003ca38\ntest    rax, rax                                                       ; +0xaf, 0x10003ca3f\njz      short loc_10003C9EE                                            ; +0xb2, 0x10003ca42\nmov     rax, [rax+38h]                                                 ; +0xb4, 0x10003ca44\nmov     ecx, [rax]                                                     ; +0xb8, 0x10003ca48\ntest    rcx, rcx                                                       ; +0xba, 0x10003ca4a\njz      short loc_10003C9EE                                            ; +0xbd, 0x10003ca4d\nmov     r15, [rax+10h]                                                 ; +0xbf, 0x10003ca4f\nlea     r12, [r15+rcx*8]                                               ; +0xc3, 0x10003ca53\nadd     r12, 0FFFFFFFFFFFFFFF8h                                        ; +0xc7, 0x10003ca57\nnop     dword ptr [rax+rax+00h]                                        ; +0xcb, 0x10003ca5b\nmov     rdi, [r15]                                                     ; +0xd0, 0x10003ca60\ntest    rdi, rdi                                                       ; +0xd3, 0x10003ca63\njz      short loc_10003C9EE                                            ; +0xd6, 0x10003ca66\ncall    GameObject__deselectObject                                     ; +0xd8, 0x10003ca68\nadd     r15, 8                                                         ; +0xdd, 0x10003ca6d\ncmp     r15, r12                                                       ; +0xe1, 0x10003ca71\njbe     short loc_10003CA60                                            ; +0xe4, 0x10003ca74\njmp     loc_10003C9EE                                                  ; +0xe6, 0x10003ca76", "xrefs": ["EditorUI::onEditColor @ 0x10002ae58", "EditorUI::checkLiveColorSelect @ 0x10003c734"], "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"}