mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2025-12-20 14:23:08 +01:00
Prevent station ends, flat rides and shops invalidating unnecessarily
This commit is contained in:
@@ -332,10 +332,12 @@ static void RideInvalidateStationStart(Ride& ride, StationIndex stationIndex, bo
|
|||||||
if (tileElement == nullptr)
|
if (tileElement == nullptr)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
tileElement->AsTrack()->SetHasGreenLight(greenLight);
|
TrackElement* const trackElement = tileElement->AsTrack();
|
||||||
|
if (trackElement->HasGreenLight() != greenLight)
|
||||||
// Invalidate map tile
|
{
|
||||||
|
trackElement->SetHasGreenLight(greenLight);
|
||||||
MapInvalidateTileZoom1({ startPos, tileElement->GetBaseZ(), tileElement->GetClearanceZ() });
|
MapInvalidateTileZoom1({ startPos, tileElement->GetBaseZ(), tileElement->GetClearanceZ() });
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
TileElement* RideGetStationStartTrackElement(const Ride& ride, StationIndex stationIndex)
|
TileElement* RideGetStationStartTrackElement(const Ride& ride, StationIndex stationIndex)
|
||||||
|
|||||||
Reference in New Issue
Block a user