From: Guus Sliepen Date: Sat, 21 Nov 2015 22:09:08 +0000 (+0100) Subject: Fix showing the minimap using the joystick. X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=9c128af2f85fb435e48ef71794cc895a8cd5a4ac;p=quix0rs-blobwars.git Fix showing the minimap using the joystick. --- diff --git a/src/game.cpp b/src/game.cpp index 29aafdf..d8f9503 100644 --- a/src/game.cpp +++ b/src/game.cpp @@ -671,6 +671,7 @@ int doGame() if (config.isControl(CONTROL::MAP)) { + config.resetControl(CONTROL::MAP); if (!map.isBossMission) { showMap((int)(player.x / 32), (int)(player.y / 32)); diff --git a/src/map.cpp b/src/map.cpp index 34dbcfa..45559d3 100644 --- a/src/map.cpp +++ b/src/map.cpp @@ -413,6 +413,9 @@ void showMap(int centerX, int centerY) if ((config.isControl(CONTROL::MAP)) || (config.isControl(CONTROL::PAUSE)) || (engine.keyState[SDL_SCANCODE_ESCAPE])) { + engine.keyState[SDL_SCANCODE_ESCAPE] = 0; + config.resetControl(CONTROL::MAP); + config.resetControl(CONTROL::PAUSE); break; }