From 4f37a3f18366876ee753b54e7237954e5eaab63c Mon Sep 17 00:00:00 2001 From: toaster Date: Mon, 1 Apr 2024 17:39:25 +0100 Subject: [PATCH] G_PlayerReborn: Clear roundcondition information on becoming a spectator (should resolve #1231) --- src/g_game.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/g_game.c b/src/g_game.c index 52764ed84..fa2ca0839 100644 --- a/src/g_game.c +++ b/src/g_game.c @@ -2267,6 +2267,8 @@ void G_PlayerReborn(INT32 player, boolean betweenmaps) rings = 5; } + saveroundconditions = false; + if (betweenmaps || leveltime < introtime) { K_StopRoulette(&itemRoulette); @@ -2288,7 +2290,6 @@ void G_PlayerReborn(INT32 player, boolean betweenmaps) lastsafecheatcheck = 0; bigwaypointgap = 0; - saveroundconditions = false; tallyactive = false; } else @@ -2328,8 +2329,11 @@ void G_PlayerReborn(INT32 player, boolean betweenmaps) pflags |= (players[player].pflags & (PF_STASIS|PF_ELIMINATED|PF_NOCONTEST|PF_FAULT|PF_LOSTLIFE)); - memcpy(&roundconditions, &players[player].roundconditions, sizeof (roundconditions)); - saveroundconditions = true; + if (spectator == false) + { + memcpy(&roundconditions, &players[player].roundconditions, sizeof (roundconditions)); + saveroundconditions = true; + } lastsafelap = players[player].lastsafelap; lastsafecheatcheck = players[player].lastsafecheatcheck;