From 9d23c1012c6a660fe3a4ed41833121f598c126b8 Mon Sep 17 00:00:00 2001 From: Mathieu Schroeter Date: Wed, 18 Oct 2017 06:40:37 +0200 Subject: [PATCH] Return in the game when ESC is used in the stop phase It prevents to lost the current game just because we use two times the ESC key. It's better to return in the game when ESCAPE is used from the STOP phase (game paused). --- src/event.cxx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/event.cxx b/src/event.cxx index 2c00926..553af96 100644 --- a/src/event.cxx +++ b/src/event.cxx @@ -5203,6 +5203,9 @@ CEvent::TreatEventBase (const SDL_Event & event) return true; case EV_PHASE_STOP: + ChangePhase (EV_PHASE_PLAY); + return true; + case EV_PHASE_LOST: case EV_PHASE_BUILD: ChangePhase (EV_PHASE_INFO);