diff --git a/src/d_clisrv.c b/src/d_clisrv.c index 9b0c1ff52..dbc95e065 100644 --- a/src/d_clisrv.c +++ b/src/d_clisrv.c @@ -5920,9 +5920,9 @@ static void Local_Maketic(INT32 realtics) INT32 i; I_OsPolling(); // I_Getevent - D_ProcessEvents(); // menu responder, cons responder, - // game responder calls HU_Responder, AM_Responder, - // and G_MapEventsToControls + D_ProcessEvents(true); // menu responder, cons responder, + // game responder calls HU_Responder, AM_Responder, + // and G_MapEventsToControls if (!dedicated) rendergametic = gametic; diff --git a/src/d_main.cpp b/src/d_main.cpp index 19fd9c1db..1ece00a2b 100644 --- a/src/d_main.cpp +++ b/src/d_main.cpp @@ -264,7 +264,7 @@ void HandleGamepadDeviceEvents(event_t *ev) // D_ProcessEvents // Send all the events of the given timestamp down the responder chain // -void D_ProcessEvents(void) +void D_ProcessEvents(boolean callresponders) { event_t *ev; int i; @@ -298,6 +298,9 @@ void D_ProcessEvents(void) // update keys current state G_MapEventsToControls(ev); + if (!callresponders) + continue; // eat + // Menu input #ifdef HAVE_THREADS I_lock_mutex(&k_menu_mutex); diff --git a/src/d_main.h b/src/d_main.h index fdaa1bc1c..a47eec7a3 100644 --- a/src/d_main.h +++ b/src/d_main.h @@ -50,7 +50,7 @@ void D_PostEvent(const event_t *ev); void D_PostEvent_end(void); // delimiter for locking memory #endif -void D_ProcessEvents(void); +void D_ProcessEvents(boolean callresponders); const char *D_Home(void); diff --git a/src/f_wipe.cpp b/src/f_wipe.cpp index 6a8587586..6c848cda1 100644 --- a/src/f_wipe.cpp +++ b/src/f_wipe.cpp @@ -553,6 +553,12 @@ void F_RunWipe(UINT8 wipemode, UINT8 wipetype, boolean drawMenu, const char *col } I_OsPolling(); + // The event buffer is rather small so we need to + // process these events immediately, to make sure + // inputs don't get stuck (would happen a lot with + // some controllers that send a lot of analog + // events). + D_ProcessEvents(false); I_UpdateNoBlit(); if (drawMenu && rendermode != render_none)