mirror of
https://github.com/huderlem/porymap.git
synced 2026-08-13 04:15:45 -05:00
api util setMainTab ignores command when in layout only mode
This commit is contained in:
@@ -144,6 +144,9 @@ void ScriptUtility::setMainTab(int index) {
|
||||
// Can't select Wild Encounters tab if it's disabled
|
||||
if (index == 4 && !userConfig.getEncounterJsonActive())
|
||||
return;
|
||||
// don't change tab when not editing a map
|
||||
if (!window->editor || !window->editor->map)
|
||||
return;
|
||||
window->on_mainTabBar_tabBarClicked(index);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user