1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-06 06:32:56 +01:00

Fix #9924: Traffic light in Ride List shows incorrect status (#9931)

This commit is contained in:
Michael Steenbeek
2019-08-24 10:45:39 +02:00
committed by GitHub
parent f7ce9b10b3
commit 7270a86eb7

View File

@@ -533,10 +533,10 @@ static void window_ride_list_invalidate(rct_window* w)
if (std::size(rideManager) != 0)
{
auto c = (RideClassification)w->page;
allClosed = std::all_of(rideManager.begin(), rideManager.end(), [c](const Ride& ride) {
allClosed = std::none_of(rideManager.begin(), rideManager.end(), [c](const Ride& ride) {
return ride.GetClassification() == c && ride.status == RIDE_STATUS_OPEN;
});
allOpen = std::all_of(rideManager.begin(), rideManager.end(), [c](const Ride& ride) {
allOpen = std::none_of(rideManager.begin(), rideManager.end(), [c](const Ride& ride) {
return ride.GetClassification() == c && ride.status != RIDE_STATUS_OPEN;
});
}