diff --git a/src/openrct2-ui/drawing/engines/opengl/OpenGLDrawingEngine.cpp b/src/openrct2-ui/drawing/engines/opengl/OpenGLDrawingEngine.cpp index 48c99a424d..35af9f7705 100644 --- a/src/openrct2-ui/drawing/engines/opengl/OpenGLDrawingEngine.cpp +++ b/src/openrct2-ui/drawing/engines/opengl/OpenGLDrawingEngine.cpp @@ -362,7 +362,7 @@ public: { WindowResetVisibilities(); - if (ClimateIsRaining() || ClimateIsSnowing() || ClimateIsSnowingHeavily()) + if (ClimateHasWeatherEffect()) { WindowUpdateAllViewports(); // OpenGL doesn't support restoring pixels, always redraw. diff --git a/src/openrct2/world/Climate.cpp b/src/openrct2/world/Climate.cpp index c11e048655..a5e115595c 100644 --- a/src/openrct2/world/Climate.cpp +++ b/src/openrct2/world/Climate.cpp @@ -288,6 +288,13 @@ bool WeatherIsDry(WeatherType weather) return weather == WeatherType::Sunny || weather == WeatherType::PartiallyCloudy || weather == WeatherType::Cloudy; } +bool ClimateHasWeatherEffect() +{ + const auto& weatherCurrent = getGameState().weatherCurrent; + // The game starts drawing rain whenever this level is not none. + return weatherCurrent.level != WeatherLevel::None; +} + FilterPaletteID ClimateGetWeatherGloomPaletteId(const WeatherState& state) { auto paletteId = FilterPaletteID::PaletteNull; diff --git a/src/openrct2/world/Climate.h b/src/openrct2/world/Climate.h index e68c5faa26..3f29e51e0a 100644 --- a/src/openrct2/world/Climate.h +++ b/src/openrct2/world/Climate.h @@ -92,5 +92,6 @@ bool ClimateTransitioningToSnow(); bool ClimateIsSnowing(); bool ClimateIsSnowingHeavily(); bool WeatherIsDry(WeatherType); +bool ClimateHasWeatherEffect(); FilterPaletteID ClimateGetWeatherGloomPaletteId(const WeatherState& state); uint32_t ClimateGetWeatherSpriteId(const WeatherType weatherType);