From aad15899fde6b305b211db5b83cafc6c9e819029 Mon Sep 17 00:00:00 2001 From: Antoine Pilote Date: Mon, 1 Apr 2024 19:21:58 -0400 Subject: [PATCH] Fixed F5 not stopping game --- Editor/src/Windows/EditorInterface.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Editor/src/Windows/EditorInterface.cpp b/Editor/src/Windows/EditorInterface.cpp index c9e93a00..564592ae 100644 --- a/Editor/src/Windows/EditorInterface.cpp +++ b/Editor/src/Windows/EditorInterface.cpp @@ -116,7 +116,7 @@ namespace Nuake { if (Engine::IsPlayMode()) { - if (ImGui::Button(ICON_FA_PAUSE, ImVec2(30, 30)) || (Input::IsKeyPressed(GLFW_KEY_F5))) + if (ImGui::Button(ICON_FA_PAUSE, ImVec2(30, 30)) || (Input::IsKeyDown(GLFW_KEY_F5))) { Engine::ExitPlayMode(); @@ -126,7 +126,7 @@ namespace Nuake { } else { - if (ImGui::Button(ICON_FA_PLAY, ImVec2(30, 30))) + if (ImGui::Button(ICON_FA_PLAY, ImVec2(30, 30)) ) { this->SceneSnapshot = Engine::GetCurrentScene()->Copy(); @@ -155,7 +155,7 @@ namespace Nuake { ImGui::BeginDisabled(); } - if ((ImGui::Button(ICON_FA_STOP, ImVec2(30, 30)) || Input::IsKeyPressed(GLFW_KEY_F8)) && Engine::IsPlayMode()) + if ((ImGui::Button(ICON_FA_STOP, ImVec2(30, 30)) || Input::IsKeyPressed(GLFW_KEY_F5)) && Engine::IsPlayMode()) { Engine::ExitPlayMode();