//
// GJBaseGameLayer::assignNewStickyGroups from 0x14032d4f0 to 0x14032d604 (276 bytes)
//
// 5 xrefs:
// > EditorUI::pasteObjects @ 0x1401c6f66
// > SetupKeyframePopup::onCustomButton @ 0x1405bbe60
// > ??> @ 0x1408b62f8
// > ??> @ 0x1408b6330
// > ??> @ 0x14091f400
//
// 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:30:30 +0000
//
void __fastcall GJBaseGameLayer::assignNewStickyGroups(__int64 a1, cocos2d::CCArray *a2)
{
cocos2d::CCDictionary *v3; // rbx
unsigned int v4; // edi
__int64 v6; // rcx
int *v7; // rbp
__int64 v8; // rcx
struct cocos2d::CCObject *v9; // rsi
__int64 v10; // rbx
__int64 i; // rdi
cocos2d::CCArray *v12; // rbx
if ( a2 )
{
v3 = nullptr;
v4 = 0;
if ( cocos2d::CCArray::count(a2) )
{
do
{
v7 = (int *)cocos2d::CCArray::objectAtIndex(a2, v4);
if ( v7[220] > 0 )
{
if ( !v3 )
v3 = (cocos2d::CCDictionary *)cocos2d::CCDictionary::create(v6);
v9 = cocos2d::CCDictionary::objectForKey(v3, v7[220]);
if ( !v9 )
{
v9 = (struct cocos2d::CCObject *)cocos2d::CCArray::create(v8);
cocos2d::CCDictionary::setObject(v3, v9, v7[220]);
}
cocos2d::CCArray::addObject(v9, (struct cocos2d::CCObject *)v7);
}
++v4;
}
while ( v4 < cocos2d::CCArray::count(a2) );
if ( v3 )
{
v10 = *((_QWORD *)v3 + 7);
if ( v10 )
{
for ( i = *(_QWORD *)(v10 + 288); ; i = *(_QWORD *)(i + 288) )
{
v12 = *(cocos2d::CCArray **)(v10 + 264);
GJBaseGameLayer::ungroupStickyObjects(a1, v12);
GJBaseGameLayer::groupStickyObjects(a1, v12);
v10 = i;
if ( !i )
break;
}
}
}
}
}
}