//
// EditLevelLayer::onEdit from 0x1000ea240 to 0x1000ea324 (228 bytes)
//
// 2 xrefs:
// > EditLevelLayer::FLAlert_Clicked @ 0x1000ec1b8
// > EditLevelLayer::init @ 0x1000e9770
//
// 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)
{
FMODAudioEngine *v3; // x20
cocos2d::CCDirector *v4; // x20
cocos2d::CCScene *v5; // x0
cocos2d::CCTransitionFade *v6; // x0
void *__p[2]; // [xsp+8h] [xbp-28h] BYREF
char v8; // [xsp+1Fh] [xbp-11h]
if ( !cocos2d::CCDirector::sharedDirector()->m_bIsTransitioning && !a1->m_exiting )
{
EditLevelLayer::closeTextInputs(a1);
((void (__fastcall *)(EditLevelLayer *, _QWORD))a1->setKeypadEnabled)(a1, 0);
a1->m_exiting = 1;
GameManager::sharedState()->m_sceneEnum = 3;
EditLevelLayer::verifyLevelName(a1);
v3 = FMODAudioEngine::sharedEngine();
GJGameLevel::getAudioFileName((__int64)a1->m_level, __p);
FMODAudioEngine::loadMusic(v3, __p, 1, 0, 0, 0, 1.0, 0.0, 1.0);
if ( v8 < 0 )
operator delete(__p[0]);
v4 = cocos2d::CCDirector::sharedDirector();
v5 = LevelEditorLayer::scene(a1->m_level, 0);
v6 = cocos2d::CCTransitionFade::create_1(0.5, v5);
cocos2d::CCDirector::replaceScene(v4, v6);
}
}