//
// PlayLayer::addToGroupOld from 0x6f4cc8 to 0x6f4dd4 (268 bytes)
//
// 1 xrefs:
// > ??> @ 0xf9a00
//
// 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:50 +0000
//
__int64 __fastcall PlayLayer::addToGroupOld(PlayLayer *this, GameObject *a2)
{
int v4; // w20
__int64 result; // x0
int v6; // w1
GJBaseGameLayer *v7; // x0
cocos2d::CCArray *StaticGroup; // x21
int GroupID; // w21
cocos2d::CCArray *Group; // x23
v4 = 0;
result = (unsigned int)*((__int16 *)a2 + 584);
if ( (int)result > 0 )
{
do
{
while ( 1 )
{
GroupID = GameObject::getGroupID(a2, v4);
Group = (cocos2d::CCArray *)GJBaseGameLayer::getGroup(this, GroupID);
if ( !(unsigned __int8)cocos2d::CCArray::containsObject(Group, a2) )
break;
v6 = GroupID;
v7 = this;
if ( *((_DWORD *)a2 + 230) == 7 )
goto LABEL_8;
LABEL_4:
StaticGroup = (cocos2d::CCArray *)GJBaseGameLayer::getStaticGroup(v7, v6);
++v4;
if ( (unsigned __int8)cocos2d::CCArray::containsObject(StaticGroup, a2) )
goto LABEL_5;
LABEL_9:
cocos2d::CCArray::addObject(StaticGroup, a2);
result = (unsigned int)*((__int16 *)a2 + 584);
if ( (int)result <= v4 )
return result;
}
cocos2d::CCArray::addObject(Group, a2);
v6 = GroupID;
v7 = this;
if ( *((_DWORD *)a2 + 230) != 7 )
goto LABEL_4;
LABEL_8:
StaticGroup = (cocos2d::CCArray *)GJBaseGameLayer::getOptimizedGroup(v7, v6);
++v4;
if ( !(unsigned __int8)cocos2d::CCArray::containsObject(StaticGroup, a2) )
goto LABEL_9;
LABEL_5:
result = (unsigned int)*((__int16 *)a2 + 584);
}
while ( (int)result > v4 );
}
return result;
}