diff --git a/src/g_inventory/a_pickups.cpp b/src/g_inventory/a_pickups.cpp index b97f1de25..ae0c4854a 100644 --- a/src/g_inventory/a_pickups.cpp +++ b/src/g_inventory/a_pickups.cpp @@ -36,28 +36,22 @@ #include #include "info.h" -#include "m_random.h" #include "p_local.h" -#include "s_sound.h" -#include "gi.h" #include "p_lnspec.h" #include "sbar.h" #include "statnums.h" #include "c_dispatch.h" #include "gstrings.h" -#include "templates.h" #include "a_morph.h" #include "a_specialspot.h" -#include "g_level.h" #include "g_game.h" #include "doomstat.h" #include "d_player.h" -#include "p_spec.h" #include "serializer.h" #include "vm.h" #include "c_functions.h" #include "g_levellocals.h" -#include "vm.h" +#include "gi.h" EXTERN_CVAR(Bool, sv_unlimited_pickup) @@ -72,7 +66,8 @@ static FString StaticLastMessage; void PrintPickupMessage(bool localview, const FString &str) { - if (str.IsNotEmpty() && localview && (StaticLastMessageTic != gametic || StaticLastMessage.Compare(str))) + // [MK] merge identical messages on same tic unless disabled in gameinfo + if (str.IsNotEmpty() && localview && (gameinfo.nomergepickupmsg || StaticLastMessageTic != gametic || StaticLastMessage.Compare(str))) { StaticLastMessageTic = gametic; StaticLastMessage = str; diff --git a/src/gi.cpp b/src/gi.cpp index 1b2b0e613..509ce200d 100644 --- a/src/gi.cpp +++ b/src/gi.cpp @@ -444,6 +444,7 @@ void FMapInfoParser::ParseGameInfo() GAMEINFOKEY_STRING(statusscreen_dm, "statscreen_dm") GAMEINFOKEY_TWODOUBLES(normforwardmove, "normforwardmove") GAMEINFOKEY_TWODOUBLES(normsidemove, "normsidemove") + GAMEINFOKEY_BOOL(nomergepickupmsg, "nomergepickupmsg") else { diff --git a/src/gi.h b/src/gi.h index c076eb99a..2e0484770 100644 --- a/src/gi.h +++ b/src/gi.h @@ -205,6 +205,7 @@ struct gameinfo_t double normforwardmove[2]; double normsidemove[2]; int fullscreenautoaspect = 0; + bool nomergepickupmsg; const char *GetFinalePage(unsigned int num) const; };