summaryrefslogtreecommitdiffstats
path: root/src/core/Frontend.cpp
diff options
context:
space:
mode:
authoreray orçunus <erayorcunus@gmail.com>2020-05-29 21:05:33 +0200
committereray orçunus <erayorcunus@gmail.com>2020-05-29 21:05:33 +0200
commit529cec565380b3c6689641ea427a1bf973014e02 (patch)
tree6caafab9dece0f1233f7ac9899d57b83ff421cce /src/core/Frontend.cpp
parentMerge pull request #603 from Fire-Head/miami (diff)
downloadre3-529cec565380b3c6689641ea427a1bf973014e02.tar
re3-529cec565380b3c6689641ea427a1bf973014e02.tar.gz
re3-529cec565380b3c6689641ea427a1bf973014e02.tar.bz2
re3-529cec565380b3c6689641ea427a1bf973014e02.tar.lz
re3-529cec565380b3c6689641ea427a1bf973014e02.tar.xz
re3-529cec565380b3c6689641ea427a1bf973014e02.tar.zst
re3-529cec565380b3c6689641ea427a1bf973014e02.zip
Diffstat (limited to 'src/core/Frontend.cpp')
-rw-r--r--src/core/Frontend.cpp21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/core/Frontend.cpp b/src/core/Frontend.cpp
index 5c861cf5..d4c251c3 100644
--- a/src/core/Frontend.cpp
+++ b/src/core/Frontend.cpp
@@ -3470,6 +3470,24 @@ CMenuManager::ProcessButtonPresses(void)
bool assumeIncrease = false;
#endif
+#ifdef USE_DEBUG_SCRIPT_LOADER
+ if (m_nCurrScreen == MENUPAGE_START_MENU || m_nCurrScreen == MENUPAGE_NEW_GAME || m_nCurrScreen == MENUPAGE_NEW_GAME_RELOAD) {
+#ifdef RW_GL3
+ if (glfwGetKey(PSGLOBAL(window), GLFW_KEY_R) == GLFW_PRESS) {
+ scriptToLoad = 1;
+ DoSettingsBeforeStartingAGame();
+ return;
+ }
+#elif defined _WIN32
+ if (GetAsyncKeyState('R') & 0x8000) {
+ scriptToLoad = 1;
+ DoSettingsBeforeStartingAGame();
+ return;
+ }
+#endif
+ }
+#endif
+
if (!m_bShowMouse && (m_nMouseOldPosX != m_nMousePosX || m_nMouseOldPosY != m_nMousePosY)) {
m_bShowMouse = true;
}
@@ -4894,6 +4912,9 @@ CMenuManager::ProcessFileActions()
}
if (m_nCurrScreen == MENUPAGE_LOADING_IN_PROGRESS) {
if (CheckSlotDataValid(m_nCurrSaveSlot)) {
+#ifdef USE_DEBUG_SCRIPT_LOADER
+ scriptToLoad = 0;
+#endif
DoSettingsBeforeStartingAGame();
m_bWantToLoad = true;
}