From 318262b47902c90eb165948813fbd7e5a92ec629 Mon Sep 17 00:00:00 2001 From: mix <167040362+mixiate@users.noreply.github.com> Date: Tue, 9 Sep 2025 22:23:10 +0100 Subject: [PATCH] Fix reverse freefall photo using the wrong track sprite This fixes the on ride photo of the reverse freefall coaster having incorrectly coloured ties due to using a sprite from the air powered coaster. This uses the station sprite from the reverse freefall coaster instead. This removes this special case in the paint code. If I remember right, it's the only function that changes colors in this way. --- distribution/changelog.txt | 1 + .../track/coaster/ReverseFreefallCoaster.cpp | 19 ++----------------- 2 files changed, 3 insertions(+), 17 deletions(-) diff --git a/distribution/changelog.txt b/distribution/changelog.txt index f8d8c5d2aa..fa389afc67 100644 --- a/distribution/changelog.txt +++ b/distribution/changelog.txt @@ -1,6 +1,7 @@ 0.4.27 (in development) ------------------------------------------------------------------------ - Improved: [#2296, #2307] The land tool now takes sloped track and paths into account when modifying land. +- Fix: [#25131] The Reverse Freefall Coaster On-ride photo section track has incorrectly coloured ties. - Fix: [#25132] Crash when trying to use simulate on incomplete ride. 0.4.26 (2025-09-06) diff --git a/src/openrct2/paint/track/coaster/ReverseFreefallCoaster.cpp b/src/openrct2/paint/track/coaster/ReverseFreefallCoaster.cpp index 1d569b0ce8..24c4cb0988 100644 --- a/src/openrct2/paint/track/coaster/ReverseFreefallCoaster.cpp +++ b/src/openrct2/paint/track/coaster/ReverseFreefallCoaster.cpp @@ -391,27 +391,12 @@ static void PaintReverseFreefallRCOnridePhoto( PaintSession& session, const Ride& ride, uint8_t trackSequence, uint8_t direction, int32_t height, const TrackElement& trackElement, SupportType supportType) { - static constexpr uint32_t imageIds[4] = { - SPR_AIR_POWERED_VERTICAL_RC_FLAT_SW_NE, - SPR_AIR_POWERED_VERTICAL_RC_FLAT_NW_SE, - SPR_AIR_POWERED_VERTICAL_RC_FLAT_SW_NE, - SPR_AIR_POWERED_VERTICAL_RC_FLAT_NW_SE, - }; - - // The straight track without booster is borrowed from the APVC. - // It has one track colour, instead of the two that the Reverse Freefall Colour has. - auto colour = session.TrackColours; - if (!trackElement.IsGhost() && !trackElement.IsHighlighted()) - { - colour = colour.WithPrimary(colour.GetSecondary()); - } - PaintAddImageAsParentRotated( - session, direction, colour.WithIndex(imageIds[direction]), { 0, 0, height }, { { 0, 6, height }, { 32, 20, 1 } }); + session, direction, session.TrackColours.WithIndex(kPiecesStation[direction]), { 0, 0, height }, + { { 0, 6, height }, { 32, 20, 1 } }); DrawSupportForSequenceA( session, supportType.wooden, trackSequence, direction, height, session.SupportColours); - ; TrackPaintUtilOnridePhotoPaint2(session, direction, trackElement, height); }