//
// SetupAreaTintTriggerPopup::determineStartValues from 0x5578f0 to 0x5579fc (268 bytes)
//
// 0 xrefs:
//
// 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 SetupAreaTintTriggerPopup::determineStartValues(SetupAreaTintTriggerPopup *a1)
{
cocos2d::CCArray *v2; // r0
cocos2d::CCArray *m_gameObjects; // r7
unsigned int v4; // r9
int v5; // r10
int v6; // r8
float v7; // r1
float v8; // r2
int v9; // r3
int v10; // r0
int v11; // r12
int v12; // r5
float v13; // r0
float v14; // r1
float v15; // r2
int v16; // r3
int v17; // r3
SetupTriggerPopup::determineStartValues(a1);
if ( a1->m_gameObject )
{
m_gameObjects = (cocos2d::CCArray *)cocos2d::CCArray::create(v2);
cocos2d::CCArray::addObject(m_gameObjects, a1->m_gameObject);
}
else
{
m_gameObjects = a1->m_gameObjects;
}
if ( m_gameObjects && cocos2d::CCArray::count(m_gameObjects) )
{
v4 = 0;
v5 = 1;
v6 = 0;
v7 = flt_AC7A1C;
v8 = flt_AC7A20;
v9 = *(_DWORD *)&word_AC7A24;
a1->m_hsvValue.h = flt_AC7A18;
a1->m_hsvValue.s = v7;
a1->m_hsvValue.v = v8;
*(_DWORD *)&a1->m_hsvValue.absoluteSaturation = v9;
while ( 1 )
{
if ( v4 >= cocos2d::CCArray::count(m_gameObjects) )
return;
v10 = cocos2d::CCArray::objectAtIndex(m_gameObjects, v4);
v11 = v10;
if ( !v6 )
{
v12 = v10 + 1424;
v13 = *(float *)(v10 + 1424);
v14 = *(float *)(v12 + 4);
v15 = *(float *)(v12 + 8);
v16 = *(_DWORD *)(v12 + 12);
if ( v5 )
{
v5 = 0;
a1->m_hsvValue.h = v13;
a1->m_hsvValue.s = v14;
a1->m_hsvValue.v = v15;
*(_DWORD *)&a1->m_hsvValue.absoluteSaturation = v16;
goto LABEL_18;
}
if ( a1->m_hsvValue.h == *(float *)v12
&& a1->m_hsvValue.s == *(float *)(v11 + 1428)
&& a1->m_hsvValue.v == *(float *)(v11 + 1432) )
{
v17 = *(unsigned __int16 *)&a1->m_hsvValue.absoluteSaturation
- (unsigned __int16)v16
+ (*(unsigned __int16 *)&a1->m_hsvValue.absoluteSaturation == (unsigned __int16)v16)
+ (unsigned __int16)v16
- *(unsigned __int16 *)&a1->m_hsvValue.absoluteSaturation;
if ( v17 )
goto LABEL_18;
}
else
{
LOBYTE(v17) = 0;
}
a1->m_hsvValue.h = -0.001;
v6 = 1;
a1->m_hsvValue.s = 0.0;
a1->m_hsvValue.v = 0.0;
a1->m_hsvValue.absoluteSaturation = v17;
a1->m_hsvValue.absoluteBrightness = v17;
}
LABEL_18:
++v4;
}
}
}