//
// GJBaseGameLayer::updateKeyframeOrder from 0x140233c10 to 0x140233cdb (203 bytes)
//
// 7 xrefs:
// > GJBaseGameLayer::addKeyframe @ 0x140233bf0
// > LevelEditorLayer::removeSpecial @ 0x1402d83c9
// > LevelEditorLayer::addKeyframe @ 0x1402e1857
// > SetupKeyframePopup::onCustomButton @ 0x140426839
// > ??> @ 0x140681114
// > ??> @ 0x140681124
// > ??> @ 0x1406cdfa4
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
void GJBaseGameLayer::updateKeyframeOrder(GJBaseGameLayer *a1, int a2)
{
cocos2d::CCArray *v2; // rax
cocos2d::CCArray *v3; // rsi
struct cocos2d::CCObject *v4; // rax
unsigned int v5; // ebx
int m_uIndexInArray_high; // r14d
char v7; // bp
int i; // edi
struct cocos2d::CCObject *v9; // rax
v2 = (cocos2d::CCArray *)cocos2d::CCDictionary::objectForKey(a1->m_keyframeGroups, a2);
v3 = v2;
if ( v2 )
{
if ( cocos2d::CCArray::count(v2) )
{
v4 = cocos2d::CCArray::objectAtIndex(v3, 0);
v5 = 0;
m_uIndexInArray_high = SHIWORD(v4[21].m_uIndexInArray);
v7 = BYTE2(v4[33].m_uOrderOfArrival);
for ( i = m_uIndexInArray_high + 1; v5 < cocos2d::CCArray::count(v3); ++v5 )
{
v9 = cocos2d::CCArray::objectAtIndex(v3, v5);
v9[33].m_eObjType = v5;
BYTE2(v9[33].m_uOrderOfArrival) = v7;
if ( v7 )
{
LOWORD(v9[21].m_uUnknown) = i++;
HIWORD(v9[21].m_uIndexInArray) = m_uIndexInArray_high;
}
}
}
}
}