{"type": "func", "start": 5369404464, "end": 5369404590, "name": "CustomizeObjectLayer::getButtonByTag", "pseudocode": "// \n// CustomizeObjectLayer::getButtonByTag from 0x1400a9c30 to 0x1400a9cae (126 bytes)\n// \n// 5 xrefs:\n// > CustomizeObjectLayer::colorSetupClosed @ 0x1400a83fc\n// > CustomizeObjectLayer::onNextColorChannel @ 0x1400a8f78\n// > CustomizeObjectLayer::toggleVisible @ 0x1400a9394\n// > CustomizeObjectLayer::updateCurrentSelection @ 0x1400a9591\n// > <???> @ 0x1406c7890\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\nButtonSprite *CustomizeObjectLayer::getButtonByTag(CustomizeObjectLayer *a1, int a2)\n{\n  unsigned int v4; // ebx\n  ButtonSprite *v5; // rdi\n\n  v4 = 0;\n  if ( !cocos2d::CCArray::count(a1->m_colorButtons) )\n    return nullptr;\n  while ( 1 )\n  {\n    v5 = (ButtonSprite *)cocos2d::CCArray::objectAtIndex(a1->m_colorButtons, v4);\n    if ( v5->getTag(v5) == a2 )\n      break;\n    if ( ++v4 >= cocos2d::CCArray::count(a1->m_colorButtons) )\n      return nullptr;\n  }\n  return v5;\n}", "assembly": "; \n; CustomizeObjectLayer::getButtonByTag from 0x1400a9c30 to 0x1400a9cae (126 bytes)\n; \n; 5 xrefs:\n; > CustomizeObjectLayer::colorSetupClosed @ 0x1400a83fc\n; > CustomizeObjectLayer::onNextColorChannel @ 0x1400a8f78\n; > CustomizeObjectLayer::toggleVisible @ 0x1400a9394\n; > CustomizeObjectLayer::updateCurrentSelection @ 0x1400a9591\n; > <???> @ 0x1406c7890\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, 0x1400a9c30\nmov     [rsp+arg_8], rbp                                               ; +0x5, 0x1400a9c35\nmov     [rsp+arg_10], rsi                                              ; +0xa, 0x1400a9c3a\npush    rdi                                                            ; +0xf, 0x1400a9c3f\nsub     rsp, 20h                                                       ; +0x10, 0x1400a9c40\nmov     rsi, rcx                                                       ; +0x14, 0x1400a9c44\nmov     ebp, edx                                                       ; +0x17, 0x1400a9c47\nmov     rcx, [rcx+2A8h]                                                ; +0x19, 0x1400a9c49\nxor     ebx, ebx                                                       ; +0x20, 0x1400a9c50\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x22, 0x1400a9c52\ntest    eax, eax                                                       ; +0x28, 0x1400a9c58\njz      short loc_1400A9C92                                            ; +0x2a, 0x1400a9c5a\nnop     dword ptr [rax+00h]                                            ; +0x2c, 0x1400a9c5c\nmov     rcx, [rsi+2A8h]                                                ; +0x30, 0x1400a9c60\nmov     edx, ebx                                                       ; +0x37, 0x1400a9c67\ncall    cs:?objectAtIndex@CCArray@cocos2d@@QEAAPEAVCCObject@2@I@Z; cocos2d::CCArray::objectAtIndex(uint) ; +0x39, 0x1400a9c69\nmov     rcx, rax                                                       ; +0x3f, 0x1400a9c6f\nmov     rdi, rax                                                       ; +0x42, 0x1400a9c72\nmov     rdx, [rax]                                                     ; +0x45, 0x1400a9c75\ncall    qword ptr [rdx+38h]                                            ; +0x48, 0x1400a9c78\ncmp     eax, ebp                                                       ; +0x4b, 0x1400a9c7b\njz      short loc_1400A9CA9                                            ; +0x4d, 0x1400a9c7d\nmov     rcx, [rsi+2A8h]                                                ; +0x4f, 0x1400a9c7f\ninc     ebx                                                            ; +0x56, 0x1400a9c86\ncall    cs:?count@CCArray@cocos2d@@QEBAIXZ; cocos2d::CCArray::count(void) ; +0x58, 0x1400a9c88\ncmp     ebx, eax                                                       ; +0x5e, 0x1400a9c8e\njb      short loc_1400A9C60                                            ; +0x60, 0x1400a9c90\nxor     eax, eax                                                       ; +0x62, 0x1400a9c92\nmov     rbx, [rsp+28h+arg_0]                                           ; +0x64, 0x1400a9c94\nmov     rbp, [rsp+28h+arg_8]                                           ; +0x69, 0x1400a9c99\nmov     rsi, [rsp+28h+arg_10]                                          ; +0x6e, 0x1400a9c9e\nadd     rsp, 20h                                                       ; +0x73, 0x1400a9ca3\npop     rdi                                                            ; +0x77, 0x1400a9ca7\nretn                                                                   ; +0x78, 0x1400a9ca8\nmov     rax, rdi                                                       ; +0x79, 0x1400a9ca9\njmp     short loc_1400A9C94                                            ; +0x7c, 0x1400a9cac", "xrefs": ["CustomizeObjectLayer::colorSetupClosed @ 0x1400a83fc", "CustomizeObjectLayer::onNextColorChannel @ 0x1400a8f78", "CustomizeObjectLayer::toggleVisible @ 0x1400a9394", "CustomizeObjectLayer::updateCurrentSelection @ 0x1400a9591", "<???> @ 0x1406c7890"], "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"}