mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2025-12-18 21:43:48 +01:00
Fix #23484: Castle station styles are erroneously remappable
This commit is contained in:
committed by
GitHub
parent
82331a4f84
commit
d97ae02db2
@@ -17,6 +17,7 @@
|
|||||||
- Fix: [#18309] Flying and Multi Dimension trains glitch when changing between inverted and uninverted track when uncap fps is on.
|
- Fix: [#18309] Flying and Multi Dimension trains glitch when changing between inverted and uninverted track when uncap fps is on.
|
||||||
- Fix: [#19506] Queue paths can be placed on level crossings by replacing an existing regular path.
|
- Fix: [#19506] Queue paths can be placed on level crossings by replacing an existing regular path.
|
||||||
- Fix: [#23443] New GOG version of RCT2 is not extracted correctly.
|
- Fix: [#23443] New GOG version of RCT2 is not extracted correctly.
|
||||||
|
- Fix: [#23484] Stray coloured pixels on castle-themed stations and Roman-themed entrances/exits (original bug).
|
||||||
- Fix: [#23486] Object selection minimum requirements can be bypassed with close window hotkey.
|
- Fix: [#23486] Object selection minimum requirements can be bypassed with close window hotkey.
|
||||||
- Fix: [#23743] Parks with guest goals over 32767 do not appear in the scenario list.
|
- Fix: [#23743] Parks with guest goals over 32767 do not appear in the scenario list.
|
||||||
- Fix: [#23844] Sound effects keep playing when loading another save.
|
- Fix: [#23844] Sound effects keep playing when loading another save.
|
||||||
|
|||||||
@@ -141,8 +141,7 @@ static void PaintRideEntranceExit(PaintSession& session, uint8_t direction, int3
|
|||||||
|
|
||||||
auto hasGlass = (stationObj->Flags & StationObjectFlags::isTransparent) != 0;
|
auto hasGlass = (stationObj->Flags & StationObjectFlags::isTransparent) != 0;
|
||||||
auto colourPrimary = ride->trackColours[0].main;
|
auto colourPrimary = ride->trackColours[0].main;
|
||||||
auto colourSecondary = ride->trackColours[0].additional;
|
auto imageTemplate = ImageId(0);
|
||||||
auto imageTemplate = ImageId(0, colourPrimary, colourSecondary);
|
|
||||||
ImageId glassImageTemplate;
|
ImageId glassImageTemplate;
|
||||||
if (hasGlass)
|
if (hasGlass)
|
||||||
{
|
{
|
||||||
@@ -158,6 +157,18 @@ static void PaintRideEntranceExit(PaintSession& session, uint8_t direction, int3
|
|||||||
{
|
{
|
||||||
imageTemplate = ImageId().WithRemap(FilterPaletteID::PaletteGhost);
|
imageTemplate = ImageId().WithRemap(FilterPaletteID::PaletteGhost);
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (stationObj->Flags & StationObjectFlags::hasPrimaryColour)
|
||||||
|
{
|
||||||
|
imageTemplate = imageTemplate.WithPrimary(colourPrimary);
|
||||||
|
}
|
||||||
|
if (stationObj->Flags & StationObjectFlags::hasSecondaryColour)
|
||||||
|
{
|
||||||
|
auto colourSecondary = ride->trackColours[0].additional;
|
||||||
|
imageTemplate = imageTemplate.WithSecondary(colourSecondary);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Format modified to stop repeated code
|
// Format modified to stop repeated code
|
||||||
|
|
||||||
|
|||||||
@@ -708,14 +708,22 @@ bool TrackPaintUtilDrawStationCovers2(
|
|||||||
imageOffset += SPR_STATION_COVER_OFFSET_TALL;
|
imageOffset += SPR_STATION_COVER_OFFSET_TALL;
|
||||||
}
|
}
|
||||||
|
|
||||||
auto imageTemplate = session.TrackColours;
|
auto imageId = session.TrackColours.WithIndex(baseImageIndex + imageOffset);
|
||||||
auto imageId = imageTemplate.WithIndex(baseImageIndex + imageOffset);
|
if (!session.TrackColours.IsRemap())
|
||||||
|
{
|
||||||
|
imageId = ImageId(baseImageIndex + imageOffset);
|
||||||
|
if (stationObject->Flags & StationObjectFlags::hasPrimaryColour)
|
||||||
|
imageId = imageId.WithPrimary(session.TrackColours.GetPrimary());
|
||||||
|
if (stationObject->Flags & StationObjectFlags::hasSecondaryColour)
|
||||||
|
imageId = imageId.WithSecondary(session.TrackColours.GetSecondary());
|
||||||
|
}
|
||||||
|
|
||||||
PaintAddImageAsParent(session, imageId, offset, boundBox);
|
PaintAddImageAsParent(session, imageId, offset, boundBox);
|
||||||
|
|
||||||
// Glass
|
// Glass
|
||||||
if (colour == TrackStationColour && (stationObject->Flags & StationObjectFlags::isTransparent))
|
if (colour == TrackStationColour && (stationObject->Flags & StationObjectFlags::isTransparent))
|
||||||
{
|
{
|
||||||
imageId = ImageId(baseImageIndex + imageOffset + 12).WithTransparency(imageTemplate.GetPrimary());
|
imageId = ImageId(baseImageIndex + imageOffset + 12).WithTransparency(session.TrackColours.GetPrimary());
|
||||||
PaintAddImageAsChild(session, imageId, offset, boundBox);
|
PaintAddImageAsChild(session, imageId, offset, boundBox);
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
|
|||||||
Reference in New Issue
Block a user