//
// LevelEditorLayer::updateDisabledObjectsLastPos from 0x79a28c to 0x79a3d4 (328 bytes)
//
// 2 xrefs:
// > ??> @ 0xfb410
// > ??> @ 0x1435f00
//
// 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:53:36 +0000
//
__int64 __fastcall LevelEditorLayer::updateDisabledObjectsLastPos(LevelEditorLayer *this, cocos2d::CCArray *a2)
{
unsigned int *v3; // x0
__int64 *v4; // x19
__int64 *v5; // x21
__int64 i; // x0
int v7; // w1
int v8; // w2
int v9; // w1
_QWORD *v10; // x3
__int64 v12; // [xsp+40h] [xbp+40h] BYREF
if ( *((unsigned __int8 *)this + 13807) < (unsigned int)(a2 != nullptr) )
{
v3 = *((unsigned int **)a2 + 7);
if ( *v3 )
{
v4 = *((__int64 **)v3 + 2);
v5 = &v4[*v3 - 1];
if ( v4 <= v5 )
{
for ( i = *v4; *v4; i = *v4 )
{
if ( *(_BYTE *)(i + 1290) )
{
v7 = *((_DWORD *)this + 236);
if ( *(_DWORD *)(i + 1236) != v7 )
{
*(_DWORD *)(i + 1236) = v7;
v12 = i;
v8 = *((_DWORD *)this + 894);
v9 = *((_DWORD *)this + 889);
if ( v8 > v9 )
{
*(_QWORD *)(*((_QWORD *)this + 419) + 8LL * v9) = i;
v9 = *((_DWORD *)this + 889);
}
else
{
v10 = *((_QWORD **)this + 420);
if ( v10 == *((_QWORD **)this + 421) )
{
std::vector::__push_back_slow_path((__int64)this + 3352, &v12);
v8 = *((_DWORD *)this + 894);
v9 = *((_DWORD *)this + 889);
}
else
{
if ( v10 )
{
*v10 = i;
v10 = *((_QWORD **)this + 420);
v8 = *((_DWORD *)this + 894);
v9 = *((_DWORD *)this + 889);
}
*((_QWORD *)this + 420) = v10 + 1;
}
*((_DWORD *)this + 894) = v8 + 1;
}
*((_DWORD *)this + 889) = v9 + 1;
}
}
if ( v5 < ++v4 )
break;
}
}
}
}
return _stack_chk_guard;
}