{"type": "func", "start": 8792064, "end": 8792212, "name": "ColorSelectPopup::onToggleTintMode", "pseudocode": "// \n// ColorSelectPopup::onToggleTintMode from 0x862800 to 0x862894 (148 bytes)\n// \n// 4 xrefs:\n// > ColorSelectPopup::onDefault @ 0x8634fc\n// > <???> @ 0xd8fb8\n// > ColorSelectPopup::init @ 0x865968\n// > <???> @ 0x15467c8\n// \n// This function is hookable on this platform (idp: arm, 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 12:55:37 +0000\n// \n\n__int64 __fastcall ColorSelectPopup::onToggleTintMode(ColorSelectPopup *this, cocos2d::CCObject *a2)\n{\n  int v3; // w1\n  __int64 result; // x0\n  _BOOL4 v5; // w1\n  cocos2d::CCArray *v6; // x0\n  unsigned int v7; // w20\n  bool v8; // cf\n  unsigned int v9; // w1\n\n  v3 = *((_DWORD *)this + 284);\n  result = *((_QWORD *)this + 85);\n  v5 = v3 != 1;\n  *((_DWORD *)this + 284) = v5;\n  if ( result )\n  {\n    *(_BYTE *)(result + 1487) = v5;\n  }\n  else\n  {\n    v6 = *((cocos2d::CCArray **)this + 86);\n    if ( v6 )\n    {\n      v7 = 0;\n      while ( 1 )\n      {\n        result = cocos2d::CCArray::count(v6);\n        v8 = v7 >= (unsigned int)result;\n        v9 = v7++;\n        if ( v8 )\n          break;\n        *(_BYTE *)(cocos2d::CCArray::objectAtIndex(*((cocos2d::CCArray **)this + 86), v9) + 1487) = *((_DWORD *)this + 284) != 0;\n        v6 = *((cocos2d::CCArray **)this + 86);\n      }\n    }\n    else\n    {\n      result = *((_QWORD *)this + 143);\n      if ( result )\n        *(_BYTE *)(result + 84) = v5;\n    }\n  }\n  return result;\n}", "assembly": "; \n; ColorSelectPopup::onToggleTintMode from 0x862800 to 0x862894 (148 bytes)\n; \n; 4 xrefs:\n; > ColorSelectPopup::onDefault @ 0x8634fc\n; > <???> @ 0xd8fb8\n; > ColorSelectPopup::init @ 0x865968\n; > <???> @ 0x15467c8\n; \n; This function is hookable on this platform (idp: arm, 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 12:55:37 +0000\n; \nSTP             X29, X30, [SP,#-0x20+var_s0]!                          ; +0x0, 0x862800\nMOV             X29, SP                                                ; +0x4, 0x862804\nSTP             X19, X20, [SP,#var_s10]                                ; +0x8, 0x862808\nMOV             X19, X0                                                ; +0xc, 0x86280c\nLDR             W1, [X0,#0x470]                                        ; +0x10, 0x862810\nLDR             X0, [X0,#0x2A8]                                        ; +0x14, 0x862814\nCMP             W1, #1                                                 ; +0x18, 0x862818\nCSET            W1, NE                                                 ; +0x1c, 0x86281c\nSTR             W1, [X19,#0x470]                                       ; +0x20, 0x862820\nCBZ             X0, loc_862838                                         ; +0x24, 0x862824\nSTRB            W1, [X0,#0x5CF]                                        ; +0x28, 0x862828\nLDP             X19, X20, [SP,#var_s10]                                ; +0x2c, 0x86282c\nLDP             X29, X30, [SP+var_s0],#0x20                            ; +0x30, 0x862830\nRET                                                                    ; +0x34, 0x862834\nLDR             X0, [X19,#0x2B0]                                       ; +0x38, 0x862838\nCBZ             X0, loc_862884                                         ; +0x3c, 0x86283c\nMOV             W20, #0                                                ; +0x40, 0x862840\nB               loc_862864                                             ; +0x44, 0x862844\nLDR             X0, [X19,#0x2B0]; this                                 ; +0x48, 0x862848\nBL              _ZN7cocos2d7CCArray13objectAtIndexEj; cocos2d::CCArray::objectAtIndex(uint) ; +0x4c, 0x86284c\nLDR             W1, [X19,#0x470]                                       ; +0x50, 0x862850\nCMP             W1, WZR                                                ; +0x54, 0x862854\nCSET            W1, NE                                                 ; +0x58, 0x862858\nSTRB            W1, [X0,#0x5CF]                                        ; +0x5c, 0x86285c\nLDR             X0, [X19,#0x2B0]; this                                 ; +0x60, 0x862860\nBL              _ZNK7cocos2d7CCArray5countEv; cocos2d::CCArray::count(void) ; +0x64, 0x862864\nCMP             W20, W0                                                ; +0x68, 0x862868\nMOV             W1, W20; unsigned int                                  ; +0x6c, 0x86286c\nADD             W20, W20, #1                                           ; +0x70, 0x862870\nB.CC            loc_862848                                             ; +0x74, 0x862874\nLDP             X19, X20, [SP,#var_s10]                                ; +0x78, 0x862878\nLDP             X29, X30, [SP+var_s0],#0x20                            ; +0x7c, 0x86287c\nRET                                                                    ; +0x80, 0x862880\nLDR             X0, [X19,#0x478]                                       ; +0x84, 0x862884\nCBZ             X0, loc_86282C                                         ; +0x88, 0x862888\nSTRB            W1, [X0,#0x54]                                         ; +0x8c, 0x86288c\nB               loc_86282C                                             ; +0x90, 0x862890", "xrefs": ["ColorSelectPopup::onDefault @ 0x8634fc", "<???> @ 0xd8fb8", "ColorSelectPopup::init @ 0x865968", "<???> @ 0x15467c8"], "is_objc": false, "is_32_bit": false, "is_64_bit": true, "idp_name": "arm", "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"}