//
// EditorPauseLayer::onResume from 0x1400dd670 to 0x1400dd839 (457 bytes)
//
// 3 xrefs:
// > EditorPauseLayer::keyBackClicked @ 0x1400de609
// > EditorPauseLayer::customSetup @ 0x1400da625
// > ??> @ 0x1406c8a24
//
// 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
//
// Hidden C++ exception states: #wind=2
void EditorPauseLayer::onResume(EditorPauseLayer *a1, cocos2d::CCObject *a2)
{
__int64 v3; // rax
cocos2d::CCTouchDispatcher *v4; // rax
EditorUI *m_editorUI; // rdi
GameManager *v6; // rcx
int IntGameVariable; // esi
GameManager *v8; // rcx
int v9; // ebp
unsigned int i; // ebx
EditButtonBar *v11; // rax
cocos2d::CCArray *m_buttonArray; // rdx
EditButtonBar *m_editButtonBar; // rcx
cocos2d::CCArray *v14; // rdx
void *v15; // [rsp+40h] [rbp+8h]
void *v16; // [rsp+40h] [rbp+8h]
if ( !a1->m_saved )
{
if ( a1->m_forcePrioRegistered )
{
a1->m_forcePrioRegistered = 0;
v3 = cocos2d::CCDirector::sharedDirector(a1);
v4 = (cocos2d::CCTouchDispatcher *)(*(__int64 (__fastcall **)(__int64))(*(_QWORD *)v3 + 144LL))(v3);
cocos2d::CCTouchDispatcher::unregisterForcePrio(v4, a1);
}
LevelEditorLayer::updateOptions(a1->m_editorLayer);
a1->m_editorLayer->m_editorUI->m_isPaused = 0;
a1->removeMeAndCleanup(a1);
m_editorUI = a1->m_editorLayer->m_editorUI;
if ( m_editorUI->m_reloadItems )
{
m_editorUI->m_reloadItems = 0;
v6 = (GameManager *)qword_1406C2ED8;
if ( !qword_1406C2ED8 )
{
v15 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v15);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
v6 = (GameManager *)qword_1406C2ED8;
}
IntGameVariable = GameManager::getIntGameVariable(v6, "0049");
v8 = (GameManager *)qword_1406C2ED8;
if ( !qword_1406C2ED8 )
{
v16 = operator new(0x668u);
qword_1406C2ED8 = sub_14017AB00(v16);
(*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2ED8 + 72LL))(qword_1406C2ED8);
v8 = (GameManager *)qword_1406C2ED8;
}
v9 = GameManager::getIntGameVariable(v8, "0050");
for ( i = 0; i < cocos2d::CCArray::count(m_editorUI->m_createButtonBars); ++i )
{
v11 = (EditButtonBar *)cocos2d::CCArray::objectAtIndex(m_editorUI->m_createButtonBars, i);
m_buttonArray = v11->m_buttonArray;
if ( m_buttonArray )
EditButtonBar::loadFromItems(v11, m_buttonArray, IntGameVariable, v9, 0);
}
m_editButtonBar = m_editorUI->m_editButtonBar;
v14 = m_editButtonBar->m_buttonArray;
if ( v14 )
EditButtonBar::loadFromItems(m_editButtonBar, v14, IntGameVariable, v9, 0);
}
}
}