//
// SetupEndPopup::determineStartValues from 0x1405b27b0 to 0x1405b28b2 (258 bytes)
//
// 4 xrefs:
// > ??> @ 0x1407f1a88
// > ??> @ 0x1408df78c
// > ??> @ 0x1408df79c
// > ??> @ 0x14092db48
//
// This function is hookable on this platform (idp: pc, 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 11:34:42 +0000
//
void __fastcall SetupEndPopup::determineStartValues(__int64 a1)
{
__int64 v2; // rcx
cocos2d::CCArray *v3; // rdi
unsigned int v4; // esi
struct cocos2d::CCObject *v5; // rax
int v6; // edx
int v7; // ecx
SetupTriggerPopup::determineStartValues();
if ( *(_QWORD *)(a1 + 680) )
{
v3 = (cocos2d::CCArray *)cocos2d::CCArray::create(v2);
cocos2d::CCArray::addObject(v3, *(struct cocos2d::CCObject **)(a1 + 680));
}
else
{
v3 = *(cocos2d::CCArray **)(a1 + 688);
}
if ( v3 )
{
if ( cocos2d::CCArray::count(v3) )
{
v4 = 0;
*(_WORD *)(a1 + 1008) = 257;
for ( *(_DWORD *)(a1 + 1012) = -1; v4 < cocos2d::CCArray::count(v3); ++v4 )
{
v5 = cocos2d::CCArray::objectAtIndex(v3, v4);
if ( !*((_BYTE *)v5 + 1777) )
*(_BYTE *)(a1 + 1008) = 0;
if ( !*((_BYTE *)v5 + 1521) )
*(_BYTE *)(a1 + 1009) = 0;
v6 = *(_DWORD *)(a1 + 1012);
v7 = *((_DWORD *)v5 + 370);
if ( v6 == -1 )
{
*(_DWORD *)(a1 + 1012) = v7;
}
else if ( v6 != v7 )
{
*(_DWORD *)(a1 + 1012) = 0;
}
}
}
}
}