//
// cocos2d::CCNode::sortAllChildrenNoIndex from 0x7c49fe to 0x7c4a8a (140 bytes)
//
// 2 xrefs:
// > cocos2d::CCNode::sortAllChildren @ 0x7c56ee
// > cocos2d::CCSpriteBatchNode::sortAllChildren @ 0x7f25c8
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// 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:00:23 +0000
//
int __fastcall cocos2d::CCNode::sortAllChildrenNoIndex(int this)
{
int v1; // r7
int *v2; // r3
_DWORD *v3; // r9
int v4; // r10
_DWORD *v5; // r8
int v6; // r4
int v7; // t1
int v8; // r5
_DWORD *i; // r6
int v10; // r11
int v11; // r11
unsigned int v12; // r11
v1 = 1;
v2 = *(int **)(*(_DWORD *)(this + 192) + 52);
v3 = (_DWORD *)v2[3];
v4 = *v2;
v5 = v3;
while ( v1 < v4 )
{
v7 = v5[1];
++v5;
v6 = v7;
v8 = v1 - 1;
for ( i = v5; v8 >= 0; --i )
{
v10 = (*(int (__fastcall **)(int))(*(_DWORD *)v6 + 52))(v6);
this = (*(int (__fastcall **)(_DWORD))(*(_DWORD *)*(i - 1) + 52))(*(i - 1));
if ( v10 >= this )
{
v11 = (*(int (__fastcall **)(int))(*(_DWORD *)v6 + 52))(v6);
this = (*(int (__fastcall **)(_DWORD))(*(_DWORD *)*(i - 1) + 52))(*(i - 1));
if ( v11 != this )
break;
v12 = (*(int (__fastcall **)(int))(*(_DWORD *)v6 + 208))(v6);
this = (*(int (__fastcall **)(_DWORD))(*(_DWORD *)*(i - 1) + 208))(*(i - 1));
if ( v12 >= this )
break;
}
--v8;
*i = *(i - 1);
}
++v1;
v3[v8 + 1] = v6;
}
return this;
}