//
// SetupCollisionTriggerPopup::determineStartValues from 0x1404191a0 to 0x14041932c (396 bytes)
//
// 5 xrefs:
// > ??> @ 0x1405e10b8
// > ??> @ 0x14069fdec
// > ??> @ 0x14069fdfc
// > ??> @ 0x1406d908c
// > ??> @ 0x1406d9098
//
// 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 SetupCollisionTriggerPopup::determineStartValues(SetupCollisionTriggerPopup *a1)
{
__int64 v2; // rcx
cocos2d::CCArray *m_gameObjects; // rdi
unsigned int v4; // esi
struct cocos2d::CCObject *v5; // rax
int m_blockAID; // edx
int m_nTag; // ecx
int m_blockBID; // edx
int v9; // ecx
int m_targetID; // edx
int m_uAutoReleaseCount; // ecx
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 )
{
if ( cocos2d::CCArray::count(m_gameObjects) )
{
v4 = 0;
*(_QWORD *)&a1->m_blockAID = -1;
a1->m_targetID = -1;
*(_DWORD *)&a1->m_activateGroup = 16843009;
for ( a1->m_targetPP = 1; v4 < cocos2d::CCArray::count(m_gameObjects); ++v4 )
{
v5 = cocos2d::CCArray::objectAtIndex(m_gameObjects, v4);
if ( !BYTE1(v5[29].m_eObjType) )
a1->m_activateGroup = 0;
if ( !BYTE3(v5[30].__vftable) )
a1->m_triggerOnExit = 0;
if ( !LOBYTE(v5[30].m_uReference) )
a1->m_targetP1 = 0;
if ( !BYTE1(v5[30].m_uReference) )
a1->m_targetP2 = 0;
if ( !BYTE2(v5[30].m_uReference) )
a1->m_targetPP = 0;
m_blockAID = a1->m_blockAID;
m_nTag = v5[30].m_nTag;
if ( m_blockAID == -1 )
{
a1->m_blockAID = m_nTag;
}
else if ( m_blockAID != m_nTag )
{
a1->m_blockAID = 0;
}
m_blockBID = a1->m_blockBID;
v9 = HIDWORD(v5[30].__vftable);
if ( m_blockBID == -1 )
{
a1->m_blockBID = v9;
}
else if ( m_blockBID != v9 )
{
a1->m_blockBID = 0;
}
m_targetID = a1->m_targetID;
m_uAutoReleaseCount = v5[26].m_uAutoReleaseCount;
if ( m_targetID == -1 )
{
a1->m_targetID = m_uAutoReleaseCount;
}
else if ( m_targetID != m_uAutoReleaseCount )
{
a1->m_targetID = 0;
}
}
}
}
}