{"type": "func", "start": 8657668, "end": 8658220, "name": "CustomizeObjectLayer::onSelectMode", "pseudocode": "// \n// CustomizeObjectLayer::onSelectMode from 0x841b04 to 0x841d2c (552 bytes)\n// \n// 6 xrefs:\n// > CustomizeObjectLayer::init @ 0x8433dc\n// > <???> @ 0x8a6f0\n// > CustomizeObjectLayer::init @ 0x842138\n// > CustomizeObjectLayer::init @ 0x842214\n// > CustomizeObjectLayer::init @ 0x843488\n// > <???> @ 0x122cb60\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::onSelectMode(CustomizeObjectLayer *a1, cocos2d::CCObject *a2)\n{\n  int v3; // w0\n  cocos2d::CCLabelBMFont *m_titleLabel; // x2\n  ButtonSprite *v5; // x0\n  const char *v6; // x1\n  ButtonSprite *v7; // x0\n  const char *v8; // x1\n  CCMenuItemSpriteExtra *m_textButton; // x0\n  ButtonSprite *v10; // x0\n  const char *v11; // x1\n  int ActiveMode; // w0\n\n  v3 = a2->getTag(a2);\n  a1->m_selectedMode = v3;\n  m_titleLabel = a1->m_titleLabel;\n  if ( v3 == 1 )\n  {\n    m_titleLabel->setString(a1->m_titleLabel, \"Base Color\");\n  }\n  else if ( v3 == 2 )\n  {\n    m_titleLabel->setString(a1->m_titleLabel, \"Detail Color\");\n  }\n  else\n  {\n    m_titleLabel->setString(a1->m_titleLabel, \"Insert Text\");\n  }\n  v5 = (ButtonSprite *)a1->m_baseButton->getNormalImage(a1->m_baseButton);\n  if ( a1->m_selectedMode == 1 )\n    v6 = \"GJ_button_03.png\";\n  else\n    v6 = \"GJ_button_04.png\";\n  ButtonSprite::updateBGImage(v5, v6);\n  v7 = (ButtonSprite *)a1->m_detailButton->getNormalImage(a1->m_detailButton);\n  if ( a1->m_selectedMode == 2 )\n    v8 = \"GJ_button_03.png\";\n  else\n    v8 = \"GJ_button_04.png\";\n  ButtonSprite::updateBGImage(v7, v8);\n  m_textButton = a1->m_textButton;\n  if ( m_textButton )\n  {\n    v10 = (ButtonSprite *)m_textButton->getNormalImage(m_textButton);\n    if ( a1->m_selectedMode == 3 )\n      v11 = \"GJ_button_03.png\";\n    else\n      v11 = \"GJ_button_04.png\";\n    ButtonSprite::updateBGImage(v10, v11);\n  }\n  CustomizeObjectLayer::toggleVisible(a1);\n  a1->m_baseColorHSV->setVisible(a1->m_baseColorHSV, a1->m_selectedMode == 1);\n  a1->m_baseColorHSV->setEnabled(a1->m_baseColorHSV, a1->m_selectedMode == 1);\n  a1->m_detailColorHSV->setVisible(a1->m_detailColorHSV, a1->m_selectedMode == 2);\n  a1->m_detailColorHSV->setEnabled(a1->m_detailColorHSV, a1->m_selectedMode == 2);\n  a1->m_liveSelectButton->setVisible(a1->m_liveSelectButton, a1->m_selectedMode != 3);\n  a1->m_liveSelectButton->setEnabled(a1->m_liveSelectButton, a1->m_selectedMode != 3);\n  CustomizeObjectLayer::updateHSVButtons(a1);\n  CustomizeObjectLayer::updateColorSprite(a1);\n  ActiveMode = CustomizeObjectLayer::getActiveMode(a1, 1);\n  CustomizeObjectLayer::updateChannelLabel(a1, ActiveMode);\n}", "assembly": "; \n; CustomizeObjectLayer::onSelectMode from 0x841b04 to 0x841d2c (552 bytes)\n; \n; 6 xrefs:\n; > CustomizeObjectLayer::init @ 0x8433dc\n; > <???> @ 0x8a6f0\n; > CustomizeObjectLayer::init @ 0x842138\n; > CustomizeObjectLayer::init @ 0x842214\n; > CustomizeObjectLayer::init @ 0x843488\n; > <???> @ 0x122cb60\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\nSTP             X29, X30, [SP,#var_20]!                                ; +0x0, 0x841b04\nMOV             X29, SP                                                ; +0x4, 0x841b08\nSTR             X19, [SP,#0x20+var_10]                                 ; +0x8, 0x841b0c\nMOV             X19, X0                                                ; +0xc, 0x841b10\nMOV             X0, X1                                                 ; +0x10, 0x841b14\nLDR             X1, [X1]                                               ; +0x14, 0x841b18\nLDR             X1, [X1,#0x40]                                         ; +0x18, 0x841b1c\nBLR             X1                                                     ; +0x1c, 0x841b20\nCMP             W0, #1                                                 ; +0x20, 0x841b24\nSTR             W0, [X19,#0x2D0]                                       ; +0x24, 0x841b28\nLDR             X2, [X19,#0x308]                                       ; +0x28, 0x841b2c\nB.EQ            loc_841D10                                             ; +0x2c, 0x841b30\nCMP             W0, #2                                                 ; +0x30, 0x841b34\nB.EQ            loc_841CE8                                             ; +0x34, 0x841b38\nMOV             X0, X2                                                 ; +0x38, 0x841b3c\nLDR             X2, [X2]                                               ; +0x3c, 0x841b40\nADRL            X1, aInsertText; \"Insert Text\"                         ; +0x40, 0x841b44\nLDR             X2, [X2,#0x390]                                        ; +0x48, 0x841b4c\nBLR             X2                                                     ; +0x4c, 0x841b50\nLDR             X1, [X19,#0x2E0]                                       ; +0x50, 0x841b54\nMOV             X0, X1                                                 ; +0x54, 0x841b58\nLDR             X1, [X1]                                               ; +0x58, 0x841b5c\nLDR             X1, [X1,#0x420]                                        ; +0x5c, 0x841b60\nBLR             X1                                                     ; +0x60, 0x841b64\nLDR             W1, [X19,#0x2D0]                                       ; +0x64, 0x841b68\nCMP             W1, #1                                                 ; +0x68, 0x841b6c\nB.EQ            loc_841CD0                                             ; +0x6c, 0x841b70\nADRL            X1, aGjButton04Png; \"GJ_button_04.png\"                 ; +0x70, 0x841b74\nBL              _ZN12ButtonSprite13updateBGImageEPKc; ButtonSprite::updateBGImage(char const*) ; +0x78, 0x841b7c\nLDR             X1, [X19,#0x2E8]                                       ; +0x7c, 0x841b80\nMOV             X0, X1                                                 ; +0x80, 0x841b84\nLDR             X1, [X1]                                               ; +0x84, 0x841b88\nLDR             X1, [X1,#0x420]                                        ; +0x88, 0x841b8c\nBLR             X1                                                     ; +0x8c, 0x841b90\nLDR             W1, [X19,#0x2D0]                                       ; +0x90, 0x841b94\nCMP             W1, #2                                                 ; +0x94, 0x841b98\nB.EQ            loc_841CDC                                             ; +0x98, 0x841b9c\nADRL            X1, aGjButton04Png; \"GJ_button_04.png\"                 ; +0x9c, 0x841ba0\nBL              _ZN12ButtonSprite13updateBGImageEPKc; ButtonSprite::updateBGImage(char const*) ; +0xa4, 0x841ba8\nLDR             X0, [X19,#0x2F0]                                       ; +0xa8, 0x841bac\nCBZ             X0, loc_841BD8                                         ; +0xac, 0x841bb0\nLDR             X1, [X0]                                               ; +0xb0, 0x841bb4\nLDR             X1, [X1,#0x420]                                        ; +0xb4, 0x841bb8\nBLR             X1                                                     ; +0xb8, 0x841bbc\nLDR             W1, [X19,#0x2D0]                                       ; +0xbc, 0x841bc0\nCMP             W1, #3                                                 ; +0xc0, 0x841bc4\nB.EQ            loc_841D04                                             ; +0xc4, 0x841bc8\nADRL            X1, aGjButton04Png; \"GJ_button_04.png\"                 ; +0xc8, 0x841bcc\nBL              _ZN12ButtonSprite13updateBGImageEPKc; ButtonSprite::updateBGImage(char const*) ; +0xd0, 0x841bd4\nMOV             X0, X19; this                                          ; +0xd4, 0x841bd8\nBL              _ZN20CustomizeObjectLayer13toggleVisibleEv; CustomizeObjectLayer::toggleVisible(void) ; +0xd8, 0x841bdc\nLDR             X1, [X19,#0x2F8]                                       ; +0xdc, 0x841be0\nLDR             W3, [X19,#0x2D0]                                       ; +0xe0, 0x841be4\nMOV             X0, X1                                                 ; +0xe4, 0x841be8\nLDR             X2, [X1]                                               ; +0xe8, 0x841bec\nCMP             W3, #1                                                 ; +0xec, 0x841bf0\nCSET            W1, EQ                                                 ; +0xf0, 0x841bf4\nLDR             X2, [X2,#0x148]                                        ; +0xf4, 0x841bf8\nBLR             X2                                                     ; +0xf8, 0x841bfc\nLDR             X1, [X19,#0x2F8]                                       ; +0xfc, 0x841c00\nLDR             W3, [X19,#0x2D0]                                       ; +0x100, 0x841c04\nMOV             X0, X1                                                 ; +0x104, 0x841c08\nLDR             X2, [X1]                                               ; +0x108, 0x841c0c\nCMP             W3, #1                                                 ; +0x10c, 0x841c10\nCSET            W1, EQ                                                 ; +0x110, 0x841c14\nLDR             X2, [X2,#0x410]                                        ; +0x114, 0x841c18\nBLR             X2                                                     ; +0x118, 0x841c1c\nLDR             X1, [X19,#0x300]                                       ; +0x11c, 0x841c20\nLDR             W3, [X19,#0x2D0]                                       ; +0x120, 0x841c24\nMOV             X0, X1                                                 ; +0x124, 0x841c28\nLDR             X2, [X1]                                               ; +0x128, 0x841c2c\nCMP             W3, #2                                                 ; +0x12c, 0x841c30\nCSET            W1, EQ                                                 ; +0x130, 0x841c34\nLDR             X2, [X2,#0x148]                                        ; +0x134, 0x841c38\nBLR             X2                                                     ; +0x138, 0x841c3c\nLDR             X1, [X19,#0x300]                                       ; +0x13c, 0x841c40\nLDR             W3, [X19,#0x2D0]                                       ; +0x140, 0x841c44\nMOV             X0, X1                                                 ; +0x144, 0x841c48\nLDR             X2, [X1]                                               ; +0x148, 0x841c4c\nCMP             W3, #2                                                 ; +0x14c, 0x841c50\nCSET            W1, EQ                                                 ; +0x150, 0x841c54\nLDR             X2, [X2,#0x410]                                        ; +0x154, 0x841c58\nBLR             X2                                                     ; +0x158, 0x841c5c\nLDR             X1, [X19,#0x378]                                       ; +0x15c, 0x841c60\nLDR             W3, [X19,#0x2D0]                                       ; +0x160, 0x841c64\nMOV             X0, X1                                                 ; +0x164, 0x841c68\nLDR             X2, [X1]                                               ; +0x168, 0x841c6c\nCMP             W3, #3                                                 ; +0x16c, 0x841c70\nCSET            W1, NE                                                 ; +0x170, 0x841c74\nLDR             X2, [X2,#0x148]                                        ; +0x174, 0x841c78\nBLR             X2                                                     ; +0x178, 0x841c7c\nLDR             X1, [X19,#0x378]                                       ; +0x17c, 0x841c80\nLDR             W3, [X19,#0x2D0]                                       ; +0x180, 0x841c84\nMOV             X0, X1                                                 ; +0x184, 0x841c88\nLDR             X2, [X1]                                               ; +0x188, 0x841c8c\nCMP             W3, #3                                                 ; +0x18c, 0x841c90\nCSET            W1, NE                                                 ; +0x190, 0x841c94\nLDR             X2, [X2,#0x410]                                        ; +0x194, 0x841c98\nBLR             X2                                                     ; +0x198, 0x841c9c\nMOV             X0, X19; this                                          ; +0x19c, 0x841ca0\nBL              _ZN20CustomizeObjectLayer16updateHSVButtonsEv; CustomizeObjectLayer::updateHSVButtons(void) ; +0x1a0, 0x841ca4\nMOV             X0, X19; this                                          ; +0x1a4, 0x841ca8\nBL              _ZN20CustomizeObjectLayer17updateColorSpriteEv; CustomizeObjectLayer::updateColorSprite(void) ; +0x1a8, 0x841cac\nMOV             X0, X19; this                                          ; +0x1ac, 0x841cb0\nMOV             W1, #1; bool                                           ; +0x1b0, 0x841cb4\nBL              _ZN20CustomizeObjectLayer13getActiveModeEb; CustomizeObjectLayer::getActiveMode(bool) ; +0x1b4, 0x841cb8\nMOV             W1, W0; GJSpecialColorSelect *                         ; +0x1b8, 0x841cbc\nMOV             X0, X19; this                                          ; +0x1bc, 0x841cc0\nLDR             X19, [SP,#0x20+var_10]                                 ; +0x1c0, 0x841cc4\nLDP             X29, X30, [SP+0x20+var_20],#0x20                       ; +0x1c4, 0x841cc8\nB               _ZN20CustomizeObjectLayer18updateChannelLabelEi; CustomizeObjectLayer::updateChannelLabel(int) ; +0x1c8, 0x841ccc\nADRL            X1, aGjButton03Png; \"GJ_button_03.png\"                 ; +0x1cc, 0x841cd0\nB               loc_841B7C                                             ; +0x1d4, 0x841cd8\nADRL            X1, aGjButton03Png; \"GJ_button_03.png\"                 ; +0x1d8, 0x841cdc\nB               loc_841BA8                                             ; +0x1e0, 0x841ce4\nMOV             X0, X2                                                 ; +0x1e4, 0x841ce8\nLDR             X2, [X2]                                               ; +0x1e8, 0x841cec\nADRL            X1, aDetailColor; \"Detail Color\"                       ; +0x1ec, 0x841cf0\nLDR             X2, [X2,#0x390]                                        ; +0x1f4, 0x841cf8\nBLR             X2                                                     ; +0x1f8, 0x841cfc\nB               loc_841B54                                             ; +0x1fc, 0x841d00\nADRL            X1, aGjButton03Png; \"GJ_button_03.png\"                 ; +0x200, 0x841d04\nB               loc_841BD4                                             ; +0x208, 0x841d0c\nMOV             X0, X2                                                 ; +0x20c, 0x841d10\nLDR             X2, [X2]                                               ; +0x210, 0x841d14\nADRL            X1, aBaseColor; \"Base Color\"                           ; +0x214, 0x841d18\nLDR             X2, [X2,#0x390]                                        ; +0x21c, 0x841d20\nBLR             X2                                                     ; +0x220, 0x841d24\nB               loc_841B54                                             ; +0x224, 0x841d28", "xrefs": ["CustomizeObjectLayer::init @ 0x8433dc", "<???> @ 0x8a6f0", "CustomizeObjectLayer::init @ 0x842138", "CustomizeObjectLayer::init @ 0x842214", "CustomizeObjectLayer::init @ 0x843488", "<???> @ 0x122cb60"], "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"}