From 6475ba3d9665aeccb935e47c4fca848f1b775a46 Mon Sep 17 00:00:00 2001 From: James R <justsomejames2@gmail.com> Date: Tue, 15 Oct 2019 19:23:24 -0700 Subject: [PATCH] Put a limit on the memes --- src/d_netcmd.c | 1 + src/doomstat.h | 1 + src/g_game.c | 3 +++ src/hu_stuff.c | 10 +++++++--- 4 files changed, 12 insertions(+), 3 deletions(-) diff --git a/src/d_netcmd.c b/src/d_netcmd.c index df01838fc..38b7feadf 100644 --- a/src/d_netcmd.c +++ b/src/d_netcmd.c @@ -479,6 +479,7 @@ boolean circuitmap = true; // SRB2kart INT32 adminplayers[MAXPLAYERS]; boolean alreadyresetdownloads; +boolean alreadydunced; /// \warning Keep this up-to-date if you add/remove/rename net text commands const char *netxcmdnames[MAXNETXCMD - 1] = diff --git a/src/doomstat.h b/src/doomstat.h index a322c48c0..4f742d7ab 100644 --- a/src/doomstat.h +++ b/src/doomstat.h @@ -554,6 +554,7 @@ extern INT32 serverplayer; extern INT32 adminplayers[MAXPLAYERS]; extern boolean alreadyresetdownloads; +extern boolean alreadydunced; /// \note put these in d_clisrv outright? diff --git a/src/g_game.c b/src/g_game.c index f10558fde..1ac418bfb 100644 --- a/src/g_game.c +++ b/src/g_game.c @@ -4665,7 +4665,10 @@ void G_InitNew(UINT8 pencoremode, const char *mapname, boolean resetplayer, bool imcontinuing = false; if (server) + { alreadyresetdownloads = false; + alreadydunced = false; + } if (!skipprecutscene && mapheaderinfo[gamemap-1]->precutscenenum && !modeattacking) // Start a custom cutscene. F_StartCustomCutscene(mapheaderinfo[gamemap-1]->precutscenenum-1, true, resetplayer); diff --git a/src/hu_stuff.c b/src/hu_stuff.c index 215fa983f..96947ce44 100644 --- a/src/hu_stuff.c +++ b/src/hu_stuff.c @@ -1008,9 +1008,13 @@ static void Got_Saycmd(UINT8 **p, INT32 playernum) { if (no == 0) { - D_CSay(va( - "%s\\is an idiot and is dumb", - player_names[playernum])); + if (! alreadydunced) + { + D_CSay(va( + "%s\\is an idiot and is dumb", + player_names[playernum])); + alreadydunced = true;/* this could get annoying */ + } } else D_StartVote(VOTE_KICK, no, playernum); -- GitLab