From ec16fd931060a7b66b87f89d1c97953d00359f9b Mon Sep 17 00:00:00 2001 From: Mitchell Richters Date: Sat, 26 Nov 2022 14:16:58 +1100 Subject: [PATCH] - Duke: Soften the blood splats in Duke when the timer is at the end. --- source/games/duke/src/actors.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/source/games/duke/src/actors.cpp b/source/games/duke/src/actors.cpp index 584deb046..789a81865 100644 --- a/source/games/duke/src/actors.cpp +++ b/source/games/duke/src/actors.cpp @@ -1229,11 +1229,12 @@ void reactor(DDukeActor* const actor, int REACTOR, int REACTOR2, int REACTORBURN void bloodsplats(DDukeActor *actor) { - if (actor->temp_data[0] < 7 * 26) + if (actor->temp_data[0] < 14 * 26) { auto offset = krandf(1); - auto zadj = (1. / 16.); - auto sadj = (1. / 12.) * REPEAT_SCALE; + auto lerp = 1. - (double(actor->temp_data[0]) / (14 * 26)); + auto zadj = (1. / 16.) * lerp; + auto sadj = (1. / 12.) * lerp * REPEAT_SCALE; actor->spr.pos.Z += zadj + offset * zadj; actor->spr.scale.Y += sadj + offset * sadj; actor->temp_data[0]++;