//
// CustomizeObjectLayer::updateCustomColorLabels from 0x84109c to 0x8411b8 (284 bytes)
//
// 6 xrefs:
// > CustomizeObjectLayer::onUpdateCustomColor @ 0x841634
// > CustomizeObjectLayer::colorSetupClosed @ 0x841858
// > CustomizeObjectLayer::onNextColorChannel @ 0x8418e4
// > CustomizeObjectLayer::updateCurrentSelection @ 0x841968
// > CustomizeObjectLayer::init @ 0x842edc
// > ??> @ 0x53d48
//
// 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::updateCustomColorLabels(CustomizeObjectLayer *a1)
{
cocos2d::CCString *v2; // x0
char *CString; // x22
CCTextInputNode *m_customColorInput; // x21
unsigned __int8 *v5; // x0
unsigned int *v6; // x2
int v7; // w1
const unsigned __int8 *v8; // [xsp+40h] [xbp+40h] BYREF
v2 = (cocos2d::CCString *)cocos2d::CCString::createWithFormat(
(cocos2d::CCString *)"%i",
(const char *)(unsigned int)a1->m_customColorChannel);
CString = (char *)cocos2d::CCString::getCString(v2);
ButtonSprite::setString(a1->m_customColorButtonSprite, CString);
m_customColorInput = a1->m_customColorInput;
sub_D153B8((int)&v8, CString);
CCTextInputNode::setString(m_customColorInput, &v8);
v5 = (unsigned __int8 *)(v8 - 24);
if ( v8 - 24 != (const unsigned __int8 *)&qword_124B6B0 )
{
if ( &pthread_create )
{
v6 = (unsigned int *)(v8 - 8);
do
v7 = __ldaxr(v6);
while ( __stlxr(v7 - 1, v6) );
}
else
{
v7 = *((_DWORD *)v8 - 2);
*((_DWORD *)v8 - 2) = v7 - 1;
}
if ( v7 <= 0 )
operator delete(v5);
}
}