//
// CustomizeObjectLayer::getButtonByTag from 0x1400a9c30 to 0x1400a9cae (126 bytes)
//
// 5 xrefs:
// > CustomizeObjectLayer::colorSetupClosed @ 0x1400a83fc
// > CustomizeObjectLayer::onNextColorChannel @ 0x1400a8f78
// > CustomizeObjectLayer::toggleVisible @ 0x1400a9394
// > CustomizeObjectLayer::updateCurrentSelection @ 0x1400a9591
// > ??> @ 0x1406c7890
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
ButtonSprite *CustomizeObjectLayer::getButtonByTag(CustomizeObjectLayer *a1, int a2)
{
unsigned int v4; // ebx
ButtonSprite *v5; // rdi
v4 = 0;
if ( !cocos2d::CCArray::count(a1->m_colorButtons) )
return nullptr;
while ( 1 )
{
v5 = (ButtonSprite *)cocos2d::CCArray::objectAtIndex(a1->m_colorButtons, v4);
if ( v5->getTag(v5) == a2 )
break;
if ( ++v4 >= cocos2d::CCArray::count(a1->m_colorButtons) )
return nullptr;
}
return v5;
}