{"type": "func", "start": 5369402800, "end": 5369402999, "name": "CustomizeObjectLayer::onUpdateCustomColor", "pseudocode": "// \n// CustomizeObjectLayer::onUpdateCustomColor from 0x1400a95b0 to 0x1400a9677 (199 bytes)\n// \n// 2 xrefs:\n// > CustomizeObjectLayer::init @ 0x1400a68b1\n// > <???> @ 0x1406c7848\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::onUpdateCustomColor(CustomizeObjectLayer *a1, cocos2d::CCObject *a2)\n{\n  int v3; // eax\n  int m_customColorChannel; // edx\n  int v5; // r8d\n  int v6; // edx\n  int v7; // eax\n  int v8; // edx\n  const char *CString; // rdx\n  cocos2d::CCString *v10; // rax\n\n  a1->m_disableTextDelegate = 1;\n  v3 = a2->getTag(a2);\n  m_customColorChannel = a1->m_customColorChannel;\n  v5 = m_customColorChannel - 1;\n  v6 = m_customColorChannel + 1;\n  if ( v3 != 1 )\n    v6 = v5;\n  if ( v6 >= 10 )\n  {\n    v7 = 999;\n    if ( v6 > 999 )\n      goto LABEL_7;\n  }\n  else\n  {\n    v6 = 10;\n  }\n  v7 = v6;\nLABEL_7:\n  a1->m_customColorChannel = v7;\n  CustomizeObjectLayer::updateCustomColorLabels(a1);\n  CustomizeObjectLayer::updateSelected(a1, a1->m_customColorChannel);\n  a1->m_disableTextDelegate = 0;\n  CustomizeObjectLayer::updateColorSprite(a1);\n  v8 = a1->m_customColorChannel;\n  if ( v8 < 1000 )\n  {\n    if ( v8 <= 0 )\n    {\n      CString = \" \";\n    }\n    else\n    {\n      v10 = cocos2d::CCString::createWithFormat(\"%i\", v8);\n      CString = cocos2d::CCString::getCString(v10);\n    }\n  }\n  else\n  {\n    CString = GJSpecialColorSelect::textForColorIdx(v8);\n  }\n  a1->m_selectedColorLabel->setString(&a1->m_selectedColorLabel->cocos2d::CCLabelProtocol, CString);\n}", "assembly": "; \n; CustomizeObjectLayer::onUpdateCustomColor from 0x1400a95b0 to 0x1400a9677 (199 bytes)\n; \n; 2 xrefs:\n; > CustomizeObjectLayer::init @ 0x1400a68b1\n; > <???> @ 0x1406c7848\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    rbx                                                            ; +0x0, 0x1400a95b0\nsub     rsp, 20h                                                       ; +0x2, 0x1400a95b2\nmov     byte ptr [rcx+382h], 1                                         ; +0x6, 0x1400a95b6\nmov     rbx, rcx                                                       ; +0xd, 0x1400a95bd\nmov     rax, [rdx]                                                     ; +0x10, 0x1400a95c0\nmov     rcx, rdx                                                       ; +0x13, 0x1400a95c3\ncall    qword ptr [rax+38h]                                            ; +0x16, 0x1400a95c6\nmov     edx, [rbx+2D4h]                                                ; +0x19, 0x1400a95c9\nlea     r8d, [rdx-1]                                                   ; +0x1f, 0x1400a95cf\ninc     edx                                                            ; +0x23, 0x1400a95d3\ncmp     eax, 1                                                         ; +0x25, 0x1400a95d5\ncmovnz  edx, r8d                                                       ; +0x28, 0x1400a95d8\ncmp     edx, 0Ah                                                       ; +0x2c, 0x1400a95dc\njge     short loc_1400A95E8                                            ; +0x2f, 0x1400a95df\nmov     edx, 0Ah                                                       ; +0x31, 0x1400a95e1\njmp     short loc_1400A95F1                                            ; +0x36, 0x1400a95e6\nmov     eax, 3E7h                                                      ; +0x38, 0x1400a95e8\ncmp     edx, eax                                                       ; +0x3d, 0x1400a95ed\njg      short loc_1400A95F3                                            ; +0x3f, 0x1400a95ef\nmov     eax, edx                                                       ; +0x41, 0x1400a95f1\nmov     rcx, rbx                                                       ; +0x43, 0x1400a95f3\nmov     [rbx+2D4h], eax                                                ; +0x46, 0x1400a95f6\ncall    CustomizeObjectLayer__updateCustomColorLabels                  ; +0x4c, 0x1400a95fc\nmov     edx, [rbx+2D4h]                                                ; +0x51, 0x1400a9601\nmov     rcx, rbx                                                       ; +0x57, 0x1400a9607\ncall    CustomizeObjectLayer__updateSelected                           ; +0x5a, 0x1400a960a\nmov     rcx, rbx                                                       ; +0x5f, 0x1400a960f\nmov     byte ptr [rbx+382h], 0                                         ; +0x62, 0x1400a9612\ncall    CustomizeObjectLayer__updateColorSprite                        ; +0x69, 0x1400a9619\nmov     edx, [rbx+2D4h]                                                ; +0x6e, 0x1400a961e\ncmp     edx, 3E8h                                                      ; +0x74, 0x1400a9624\njl      short loc_1400A9638                                            ; +0x7a, 0x1400a962a\nmov     ecx, edx                                                       ; +0x7c, 0x1400a962c\ncall    GJSpecialColorSelect__textForColorIdx                          ; +0x7e, 0x1400a962e\nmov     rdx, rax                                                       ; +0x83, 0x1400a9633\njmp     short loc_1400A965E                                            ; +0x86, 0x1400a9636\ntest    edx, edx                                                       ; +0x88, 0x1400a9638\njle     short loc_1400A9657                                            ; +0x8a, 0x1400a963a\nlea     rcx, aI_11; \"%i\"                                               ; +0x8c, 0x1400a963c\ncall    cs:?createWithFormat@CCString@cocos2d@@SAPEAV12@PEBDZZ; cocos2d::CCString::createWithFormat(char const *,...) ; +0x93, 0x1400a9643\nmov     rcx, rax                                                       ; +0x99, 0x1400a9649\ncall    cs:?getCString@CCString@cocos2d@@QEBAPEBDXZ; cocos2d::CCString::getCString(void) ; +0x9c, 0x1400a964c\nmov     rdx, rax                                                       ; +0xa2, 0x1400a9652\njmp     short loc_1400A965E                                            ; +0xa5, 0x1400a9655\nlea     rdx, asc_140518984; \" \"                                        ; +0xa7, 0x1400a9657\nmov     rcx, [rbx+310h]                                                ; +0xae, 0x1400a965e\nadd     rcx, 168h                                                      ; +0xb5, 0x1400a9665\nmov     rax, [rcx]                                                     ; +0xbc, 0x1400a966c\nadd     rsp, 20h                                                       ; +0xbf, 0x1400a966f\npop     rbx                                                            ; +0xc3, 0x1400a9673\njmp     qword ptr [rax]                                                ; +0xc4, 0x1400a9674", "xrefs": ["CustomizeObjectLayer::init @ 0x1400a68b1", "<???> @ 0x1406c7848"], "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"}