//
// CustomizeObjectLayer::onUpdateCustomColor from 0x1400a95b0 to 0x1400a9677 (199 bytes)
//
// 2 xrefs:
// > CustomizeObjectLayer::init @ 0x1400a68b1
// > ??> @ 0x1406c7848
//
// 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
//
void CustomizeObjectLayer::onUpdateCustomColor(CustomizeObjectLayer *a1, cocos2d::CCObject *a2)
{
int v3; // eax
int m_customColorChannel; // edx
int v5; // r8d
int v6; // edx
int v7; // eax
int v8; // edx
const char *CString; // rdx
cocos2d::CCString *v10; // rax
a1->m_disableTextDelegate = 1;
v3 = a2->getTag(a2);
m_customColorChannel = a1->m_customColorChannel;
v5 = m_customColorChannel - 1;
v6 = m_customColorChannel + 1;
if ( v3 != 1 )
v6 = v5;
if ( v6 >= 10 )
{
v7 = 999;
if ( v6 > 999 )
goto LABEL_7;
}
else
{
v6 = 10;
}
v7 = v6;
LABEL_7:
a1->m_customColorChannel = v7;
CustomizeObjectLayer::updateCustomColorLabels(a1);
CustomizeObjectLayer::updateSelected(a1, a1->m_customColorChannel);
a1->m_disableTextDelegate = 0;
CustomizeObjectLayer::updateColorSprite(a1);
v8 = a1->m_customColorChannel;
if ( v8 < 1000 )
{
if ( v8 <= 0 )
{
CString = " ";
}
else
{
v10 = cocos2d::CCString::createWithFormat("%i", v8);
CString = cocos2d::CCString::getCString(v10);
}
}
else
{
CString = GJSpecialColorSelect::textForColorIdx(v8);
}
a1->m_selectedColorLabel->setString(&a1->m_selectedColorLabel->cocos2d::CCLabelProtocol, CString);
}