From 3836cfddcba62f6eee7d2d14a2fb63f2b1318217 Mon Sep 17 00:00:00 2001 From: toaster Date: Tue, 17 Oct 2023 12:49:50 +0100 Subject: [PATCH] UCRP_UFOATTACKMETHOD: Only check roundconditions the frame the UFO is destroyed, not hit --- src/objects/ufo.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/src/objects/ufo.c b/src/objects/ufo.c index 5e1a721e6..10da8e7ff 100644 --- a/src/objects/ufo.c +++ b/src/objects/ufo.c @@ -855,7 +855,6 @@ static UINT8 GetUFODamage(mobj_t *inflictor, UINT8 damageType) if (players[g_localplayers[i]].spectator) continue; players[i].roundconditions.ufodamaging |= ufodamaging; - players[i].roundconditions.checkthisframe = true; } } @@ -929,6 +928,18 @@ boolean Obj_SpecialUFODamage(mobj_t *ufo, mobj_t *inflictor, mobj_t *source, UIN // Destroy the UFO parts, and make the emerald collectible! UFOKillPieces(ufo); + { + UINT8 i; + for (i = 0; i <= splitscreen; i++) + { + if (!playeringame[g_localplayers[i]]) + continue; + if (players[g_localplayers[i]].spectator) + continue; + players[i].roundconditions.checkthisframe = true; + } + } + ufo->flags = (ufo->flags & ~MF_SHOOTABLE) | (MF_SPECIAL|MF_PICKUPFROMBELOW); ufo->shadowscale = FRACUNIT/3;