//
// PlayLayer::removeAllObjects from 0x6f75ec to 0x6f770c (288 bytes)
//
// 3 xrefs:
// > PlayLayer::setupHasCompleted @ 0x7084dc
// > EndLevelLayer::onEdit @ 0x8f9804
// > ??> @ 0xee630
//
// 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 12:51:51 +0000
//
__int64 __fastcall PlayLayer::removeAllObjects(PlayLayer *this)
{
cocos2d::CCArray *v2; // x0
unsigned int *v3; // x2
__int64 *v4; // x20
__int64 *v5; // x22
__int64 v6; // x19
*((_BYTE *)this + 14184) = 0;
UILayer::disableMenu(*((UILayer **)this + 1661));
(*(void (__fastcall **)(_QWORD, __int64))(**((_QWORD **)this + 407) + 1312LL))(*((_QWORD *)this + 407), 1);
PlayerObject::deactivateParticle(*((PlayerObject **)this + 407));
PlayerObject::deactivateStreak(*((PlayerObject **)this + 407), 1);
PlayerObject::toggleGhostEffect(*((_QWORD *)this + 407), 0);
if ( *((_BYTE *)this + 1010) )
{
(*(void (__fastcall **)(_QWORD, __int64))(**((_QWORD **)this + 408) + 1312LL))(*((_QWORD *)this + 408), 1);
PlayerObject::deactivateParticle(*((PlayerObject **)this + 408));
PlayerObject::deactivateStreak(*((PlayerObject **)this + 408), 1);
PlayerObject::toggleGhostEffect(*((_QWORD *)this + 408), 0);
}
v2 = *((cocos2d::CCArray **)this + 410);
if ( v2 )
{
v3 = *((unsigned int **)v2 + 7);
if ( *v3 )
{
v4 = *((__int64 **)v3 + 2);
v5 = &v4[*v3 - 1];
if ( v4 <= v5 )
{
v6 = *v4;
if ( *v4 )
{
do
{
++v4;
(*(void (__fastcall **)(__int64, __int64))(*(_QWORD *)v6 + 1312LL))(v6, 1);
(*(void (__fastcall **)(__int64))(*(_QWORD *)v6 + 736LL))(v6);
if ( v5 < v4 )
break;
v6 = *v4;
}
while ( *v4 );
v2 = *((cocos2d::CCArray **)this + 410);
}
}
}
}
return cocos2d::CCArray::removeAllObjects(v2);
}