//
// CustomizeObjectLayer::onNextColorChannel from 0x100058740 to 0x1000587d4 (148 bytes)
//
// 1 xrefs:
// > CustomizeObjectLayer::init @ 0x1000577a8
//
// This function is hookable on this platform (idp: arm, 32 bit: False, 64 bit: True!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 10:57:46 +0000
//
__int64 __fastcall CustomizeObjectLayer::onNextColorChannel(__int64 a1)
{
__int64 v2; // x0
__int64 NextColorChannel; // x0
__int64 v4; // x20
__int64 v5; // x21
__int64 ButtonByTag; // x0
v2 = GameManager::sharedState(a1);
NextColorChannel = LevelEditorLayer::getNextColorChannel(*(_QWORD *)(v2 + 552));
v4 = NextColorChannel;
v5 = NextColorChannel;
if ( (unsigned int)(NextColorChannel - 10) <= 0x3DD )
{
*(_DWORD *)(a1 + 748) = NextColorChannel;
*(_BYTE *)(a1 + 922) = 1;
CustomizeObjectLayer::updateCustomColorLabels(a1);
*(_BYTE *)(a1 + 922) = 0;
v5 = 1008;
}
CustomizeObjectLayer::updateSelected(a1, v4);
ButtonByTag = CustomizeObjectLayer::getButtonByTag(a1, v5);
CustomizeObjectLayer::highlightSelected(a1, ButtonByTag);
CustomizeObjectLayer::updateColorSprite(a1);
return CustomizeObjectLayer::updateChannelLabel(a1, v4);
}