//
// EditLevelLayer::onEdit from 0x1001fbcd0 to 0x1001fbe09 (313 bytes)
//
// 2 xrefs:
// > EditLevelLayer::FLAlert_Clicked @ 0x1001fe231
// > EditLevelLayer::init @ 0x1001fb257
//
// 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 __fastcall EditLevelLayer::onEdit(EditLevelLayer *a1, cocos2d::CCObject *a2)
{
unsigned int v2; // r14d
__int64 v3; // rax
FMODAudioEngine *v4; // r14
cocos2d::CCDirector *v5; // r14
cocos2d::CCScene *v6; // rax
cocos2d::CCTransitionFade *v7; // rax
_BYTE v8[16]; // [rsp+0h] [rbp-30h] BYREF
void *__p; // [rsp+10h] [rbp-20h]
if ( !cocos2d::CCDirector::sharedDirector()->m_bIsTransitioning && !a1->m_exiting )
{
if ( (unsigned int)sub_100720070(a1->m_textInputs) )
{
v2 = 0;
do
{
v3 = sub_1007200C0(a1->m_textInputs, v2);
(*(void (__fastcall **)(__int64, _QWORD))(*(_QWORD *)v3 + 1144LL))(v3, 0);
++v2;
}
while ( v2 < (unsigned int)sub_100720070(a1->m_textInputs) );
}
((void (__fastcall *)(EditLevelLayer *, _QWORD))a1->setKeypadEnabled)(a1, 0);
a1->m_exiting = 1;
GameManager::sharedState()->m_sceneEnum = 3;
EditLevelLayer::verifyLevelName(a1);
v4 = FMODAudioEngine::sharedEngine();
GJGameLevel::getAudioFileName(v8, a1->m_level);
FMODAudioEngine::loadMusic(v4, v8, 1, 0, 0, 0, 1.0, 0.0, 1.0);
if ( (v8[0] & 1) != 0 )
operator delete(__p);
v5 = cocos2d::CCDirector::sharedDirector();
v6 = LevelEditorLayer::scene(a1->m_level, 0);
v7 = cocos2d::CCTransitionFade::create_1(0.5, v6);
cocos2d::CCDirector::replaceScene(v5, v7);
}
}