//
// SetGroupIDLayer::updateZOrder from 0x140593db0 to 0x140593e50 (160 bytes)
//
// 3 xrefs:
// > SetGroupIDLayer::onArrow @ 0x140591587
// > SetGroupIDLayer::textChanged @ 0x140592074
// > ??> @ 0x14092cf0c
//
// 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:33 +0000
//
int __fastcall SetGroupIDLayer::updateZOrder(__int64 a1)
{
unsigned int v1; // edi
__int64 v3; // rcx
__int64 v4; // rax
struct cocos2d::CCObject *v5; // rax
v1 = 0;
*(_DWORD *)(a1 + 780) = 0;
v3 = *(_QWORD *)(a1 + 672);
if ( v3 )
{
*(_DWORD *)(v3 + 1136) = *(_DWORD *)(a1 + 776);
v4 = *(_QWORD *)(a1 + 672);
*(_BYTE *)(v4 + 1156) = 1;
}
else
{
LODWORD(v4) = cocos2d::CCArray::count(*(cocos2d::CCArray **)(a1 + 680));
if ( (_DWORD)v4 )
{
do
{
v5 = cocos2d::CCArray::objectAtIndex(*(cocos2d::CCArray **)(a1 + 680), v1++);
*((_DWORD *)v5 + 284) = *(_DWORD *)(a1 + 776);
*((_BYTE *)v5 + 1156) = 1;
LODWORD(v4) = cocos2d::CCArray::count(*(cocos2d::CCArray **)(a1 + 680));
}
while ( v1 < (unsigned int)v4 );
}
}
return v4;
}