mirror of
https://github.com/ZDoom/raze-gles.git
synced 2025-01-15 20:20:54 +00:00
- clear the input state when starting a new map or loading a savegame.
This commit is contained in:
parent
99161e2e4a
commit
866be28da0
3 changed files with 2 additions and 3 deletions
|
@ -2611,6 +2611,7 @@ int32_t(*loadboard_replace)(const char *filename, char flags, vec3_t *dapos, int
|
||||||
// <= -4: map-text error
|
// <= -4: map-text error
|
||||||
int32_t engineLoadBoard(const char *filename, char flags, vec3_t *dapos, int16_t *daang, int16_t *dacursectnum)
|
int32_t engineLoadBoard(const char *filename, char flags, vec3_t *dapos, int16_t *daang, int16_t *dacursectnum)
|
||||||
{
|
{
|
||||||
|
inputState.ClearAllInput();
|
||||||
if (loadboard_replace)
|
if (loadboard_replace)
|
||||||
return loadboard_replace(filename, flags, dapos, daang, dacursectnum);
|
return loadboard_replace(filename, flags, dapos, daang, dacursectnum);
|
||||||
int32_t i;
|
int32_t i;
|
||||||
|
|
|
@ -964,6 +964,7 @@ void M_ClearMenus (bool final)
|
||||||
CurrentMenu = nullptr;
|
CurrentMenu = nullptr;
|
||||||
menuactive = MENU_Off;
|
menuactive = MENU_Off;
|
||||||
M_UnpauseSound();
|
M_UnpauseSound();
|
||||||
|
inputState.ClearAllInput();
|
||||||
if (!final)
|
if (!final)
|
||||||
{
|
{
|
||||||
gi->MenuClosed();
|
gi->MenuClosed();
|
||||||
|
|
|
@ -261,9 +261,6 @@ void GameInterface::MenuClosed()
|
||||||
auto& gm = ps[myconnectindex].gm;
|
auto& gm = ps[myconnectindex].gm;
|
||||||
if (gm & MODE_GAME)
|
if (gm & MODE_GAME)
|
||||||
{
|
{
|
||||||
if (gm & MODE_MENU)
|
|
||||||
inputState.ClearAllInput();
|
|
||||||
|
|
||||||
// The following lines are here so that you cannot close the menu when no game is running.
|
// The following lines are here so that you cannot close the menu when no game is running.
|
||||||
gm &= ~MODE_MENU;
|
gm &= ~MODE_MENU;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue