{"type": "func", "start": 5369401856, "end": 5369402291, "name": "CustomizeObjectLayer::toggleVisible", "pseudocode": "// \n// CustomizeObjectLayer::toggleVisible from 0x1400a9200 to 0x1400a93b3 (435 bytes)\n// \n// 2 xrefs:\n// > CustomizeObjectLayer::onSelectMode @ 0x1400a90d8\n// > <???> @ 0x1406c780c\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 CustomizeObjectLayer::toggleVisible(CustomizeObjectLayer *a1)\n{\n  unsigned int v2; // edi\n  unsigned int i; // esi\n  struct cocos2d::CCObject *v4; // rax\n  __int64 v5; // rdx\n  unsigned int j; // esi\n  struct cocos2d::CCObject *v7; // rax\n  __int64 v8; // rdx\n  struct cocos2d::CCObject *v9; // rax\n  CCTextInputNode *m_textInput; // rcx\n  int ActiveMode; // eax\n  ButtonSprite *ButtonByTag; // rax\n\n  v2 = 0;\n  a1->m_showTextInput = a1->m_selectedMode == 3;\n  for ( i = 0; i < cocos2d::CCArray::count(a1->m_colorTabNodes); ++i )\n  {\n    v4 = cocos2d::CCArray::objectAtIndex(a1->m_colorTabNodes, i);\n    LOBYTE(v5) = !a1->m_showTextInput;\n    ((void (__fastcall *)(struct cocos2d::CCObject *, __int64))v4->__vftable[4].update)(v4, v5);\n  }\n  for ( j = 0; j < cocos2d::CCArray::count(a1->m_detailTabNodes); ++j )\n  {\n    v7 = cocos2d::CCArray::objectAtIndex(a1->m_detailTabNodes, j);\n    LOBYTE(v8) = !a1->m_showTextInput;\n    ((void (__fastcall *)(struct cocos2d::CCObject *, __int64))v7->__vftable[4].update)(v7, v8);\n  }\n  if ( a1->m_customColorSelected )\n  {\n    if ( cocos2d::CCArray::count(a1->m_textTabNodes) )\n    {\n      do\n      {\n        v9 = cocos2d::CCArray::objectAtIndex(a1->m_textTabNodes, v2);\n        ((void (__fastcall *)(struct cocos2d::CCObject *, bool))v9->__vftable[4].update)(v9, a1->m_showTextInput);\n        ++v2;\n      }\n      while ( v2 < cocos2d::CCArray::count(a1->m_textTabNodes) );\n    }\n    m_textInput = a1->m_textInput;\n    if ( m_textInput )\n    {\n      m_textInput->setTouchEnabled(m_textInput, a1->m_showTextInput);\n      a1->m_textInput->setVisible(a1->m_textInput, a1->m_showTextInput);\n    }\n  }\n  ActiveMode = CustomizeObjectLayer::getActiveMode(a1, 0);\n  if ( (unsigned int)(ActiveMode - 10) <= 0x3DD )\n  {\n    a1->m_disableTextDelegate = 1;\n    a1->m_customColorChannel = ActiveMode;\n    CustomizeObjectLayer::updateCustomColorLabels(a1);\n    ActiveMode = 1008;\n    a1->m_disableTextDelegate = 0;\n  }\n  ButtonByTag = CustomizeObjectLayer::getButtonByTag(a1, ActiveMode);\n  CustomizeObjectLayer::highlightSelected(a1, ButtonByTag);\n}", "assembly": "; \n; CustomizeObjectLayer::toggleVisible from 0x1400a9200 to 0x1400a93b3 (435 bytes)\n; \n; 2 xrefs:\n; > CustomizeObjectLayer::onSelectMode @ 0x1400a90d8\n; > <???> @ 0x1406c780c\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_0], rbx                                               ; +0x0, 0x1400a9200\nmov     [rsp+arg_8], rsi                                               ; +0x5, 0x1400a9205\npush    rdi                                                            ; +0xa, 0x1400a920a\nsub     rsp, 20h                                                       ; +0xb, 0x1400a920b\ncmp     dword ptr [rcx+2D0h], 3                                        ; +0xf, 0x1400a920f\nmov     rbx, rcx                                                       ; +0x16, 0x1400a9216\nsetz    al                                                             ; +0x19, 0x1400a9219\nxor     edi, edi                                                       ; +0x1c, 0x1400a921c\nmov     [rcx+380h], al                                                 ; +0x1e, 0x1400a921e\nmov     esi, edi                                                       ; +0x24, 0x1400a9224\nmov     rcx, [rcx+2B0h]                                                ; +0x26, 0x1400a9226\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x2d, 0x1400a922d\ntest    eax, eax                                                       ; +0x33, 0x1400a9233\njz      short loc_1400A9279                                            ; +0x35, 0x1400a9235\nnop     word ptr [rax+rax+00000000h]                                   ; +0x37, 0x1400a9237\nmov     rcx, [rbx+2B0h]                                                ; +0x40, 0x1400a9240\nmov     edx, esi                                                       ; +0x47, 0x1400a9247\ncall    cs:?objectAtIndex@CCArray@cocos2d@@QEAAPEAVCCObject@2@I@Z; cocos2d::CCArray::objectAtIndex(uint) ; +0x49, 0x1400a9249\ncmp     [rbx+380h], dil                                                ; +0x4f, 0x1400a924f\nmov     rcx, rax                                                       ; +0x56, 0x1400a9256\nsetz    dl                                                             ; +0x59, 0x1400a9259\nmov     r8, [rax]                                                      ; +0x5c, 0x1400a925c\ncall    qword ptr [r8+140h]                                            ; +0x5f, 0x1400a925f\nmov     rcx, [rbx+2B0h]                                                ; +0x66, 0x1400a9266\ninc     esi                                                            ; +0x6d, 0x1400a926d\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x6f, 0x1400a926f\ncmp     esi, eax                                                       ; +0x75, 0x1400a9275\njb      short loc_1400A9240                                            ; +0x77, 0x1400a9277\nmov     rcx, [rbx+2C8h]                                                ; +0x79, 0x1400a9279\nmov     esi, edi                                                       ; +0x80, 0x1400a9280\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x82, 0x1400a9282\ntest    eax, eax                                                       ; +0x88, 0x1400a9288\njz      short loc_1400A92C9                                            ; +0x8a, 0x1400a928a\nnop     dword ptr [rax+00h]                                            ; +0x8c, 0x1400a928c\nmov     rcx, [rbx+2C8h]                                                ; +0x90, 0x1400a9290\nmov     edx, esi                                                       ; +0x97, 0x1400a9297\ncall    cs:?objectAtIndex@CCArray@cocos2d@@QEAAPEAVCCObject@2@I@Z; cocos2d::CCArray::objectAtIndex(uint) ; +0x99, 0x1400a9299\ncmp     [rbx+380h], dil                                                ; +0x9f, 0x1400a929f\nmov     rcx, rax                                                       ; +0xa6, 0x1400a92a6\nsetz    dl                                                             ; +0xa9, 0x1400a92a9\nmov     r8, [rax]                                                      ; +0xac, 0x1400a92ac\ncall    qword ptr [r8+140h]                                            ; +0xaf, 0x1400a92af\nmov     rcx, [rbx+2C8h]                                                ; +0xb6, 0x1400a92b6\ninc     esi                                                            ; +0xbd, 0x1400a92bd\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0xbf, 0x1400a92bf\ncmp     esi, eax                                                       ; +0xc5, 0x1400a92c5\njb      short loc_1400A9290                                            ; +0xc7, 0x1400a92c7\ncmp     [rbx+381h], dil                                                ; +0xc9, 0x1400a92c9\njz      loc_1400A9359                                                  ; +0xd0, 0x1400a92d0\nmov     rcx, [rbx+2B8h]                                                ; +0xd6, 0x1400a92d6\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0xdd, 0x1400a92dd\ntest    eax, eax                                                       ; +0xe3, 0x1400a92e3\njz      short loc_1400A9326                                            ; +0xe5, 0x1400a92e5\nnop     word ptr [rax+rax+00000000h]                                   ; +0xe7, 0x1400a92e7\nmov     rcx, [rbx+2B8h]                                                ; +0xf0, 0x1400a92f0\nmov     edx, edi                                                       ; +0xf7, 0x1400a92f7\ncall    cs:?objectAtIndex@CCArray@cocos2d@@QEAAPEAVCCObject@2@I@Z; cocos2d::CCArray::objectAtIndex(uint) ; +0xf9, 0x1400a92f9\nmovzx   edx, byte ptr [rbx+380h]                                       ; +0xff, 0x1400a92ff\nmov     rcx, rax                                                       ; +0x106, 0x1400a9306\nmov     r8, [rax]                                                      ; +0x109, 0x1400a9309\ncall    qword ptr [r8+140h]                                            ; +0x10c, 0x1400a930c\nmov     rcx, [rbx+2B8h]                                                ; +0x113, 0x1400a9313\ninc     edi                                                            ; +0x11a, 0x1400a931a\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x11c, 0x1400a931c\ncmp     edi, eax                                                       ; +0x122, 0x1400a9322\njb      short loc_1400A92F0                                            ; +0x124, 0x1400a9324\nmov     rcx, [rbx+320h]                                                ; +0x126, 0x1400a9326\ntest    rcx, rcx                                                       ; +0x12d, 0x1400a932d\njz      short loc_1400A9359                                            ; +0x130, 0x1400a9330\nmov     rax, [rcx]                                                     ; +0x132, 0x1400a9332\nmovzx   edx, byte ptr [rbx+380h]                                       ; +0x135, 0x1400a9335\ncall    qword ptr [rax+388h]                                           ; +0x13c, 0x1400a933c\nmov     rcx, [rbx+320h]                                                ; +0x142, 0x1400a9342\nmovzx   edx, byte ptr [rbx+380h]                                       ; +0x149, 0x1400a9349\nmov     rax, [rcx]                                                     ; +0x150, 0x1400a9350\ncall    qword ptr [rax+140h]                                           ; +0x153, 0x1400a9353\nxor     edx, edx                                                       ; +0x159, 0x1400a9359\nmov     rcx, rbx                                                       ; +0x15b, 0x1400a935b\ncall    CustomizeObjectLayer__getActiveMode                            ; +0x15e, 0x1400a935e\nlea     ecx, [rax-0Ah]                                                 ; +0x163, 0x1400a9363\ncmp     ecx, 3DDh                                                      ; +0x166, 0x1400a9366\nja      short loc_1400A938F                                            ; +0x16c, 0x1400a936c\nmov     rcx, rbx                                                       ; +0x16e, 0x1400a936e\nmov     byte ptr [rbx+382h], 1                                         ; +0x171, 0x1400a9371\nmov     [rbx+2D4h], eax                                                ; +0x178, 0x1400a9378\ncall    CustomizeObjectLayer__updateCustomColorLabels                  ; +0x17e, 0x1400a937e\nmov     eax, 3F0h                                                      ; +0x183, 0x1400a9383\nmov     byte ptr [rbx+382h], 0                                         ; +0x188, 0x1400a9388\nmov     edx, eax                                                       ; +0x18f, 0x1400a938f\nmov     rcx, rbx                                                       ; +0x191, 0x1400a9391\ncall    CustomizeObjectLayer__getButtonByTag                           ; +0x194, 0x1400a9394\nmov     rdx, rax                                                       ; +0x199, 0x1400a9399\nmov     rcx, rbx                                                       ; +0x19c, 0x1400a939c\nmov     rbx, [rsp+28h+arg_0]                                           ; +0x19f, 0x1400a939f\nmov     rsi, [rsp+28h+arg_8]                                           ; +0x1a4, 0x1400a93a4\nadd     rsp, 20h                                                       ; +0x1a9, 0x1400a93a9\npop     rdi                                                            ; +0x1ad, 0x1400a93ad\njmp     CustomizeObjectLayer__highlightSelected                        ; +0x1ae, 0x1400a93ae", "xrefs": ["CustomizeObjectLayer::onSelectMode @ 0x1400a90d8", "<???> @ 0x1406c780c"], "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"}