mirror of https://github.com/OpenRCT2/OpenRCT2.git
Fix rain gloom. Mistake in viewport_paint caused no change in gloom
This commit is contained in:
parent
46bf391989
commit
cfd83eca1d
|
@ -1055,7 +1055,7 @@ void viewport_paint(rct_viewport* viewport, rct_drawpixelinfo* dpi, int left, in
|
|||
//RCT2_CALLPROC_EBPSAFE(0x688485); //Big function call
|
||||
|
||||
int weather_colour = RCT2_ADDRESS(0x98195C, uint32)[RCT2_GLOBAL(RCT2_ADDRESS_CURRENT_WEATHER_GLOOM, uint8)];
|
||||
if ((weather_colour != -1) && (RCT2_GLOBAL(RCT2_ADDRESS_CURRENT_VIEWPORT_FLAGS, uint16) & 0x4000) && (RCT2_GLOBAL(0x9DEA6F, uint8) & 1)){
|
||||
if ((weather_colour != -1) && (!(RCT2_GLOBAL(RCT2_ADDRESS_CURRENT_VIEWPORT_FLAGS, uint16) & 0x4000)) && (!(RCT2_GLOBAL(0x9DEA6F, uint8) & 1))){
|
||||
dpi2 = RCT2_GLOBAL(0x140E9A8, rct_drawpixelinfo*);
|
||||
gfx_fill_rect(dpi2, dpi2->x, dpi2->y, dpi2->width + dpi2->x - 1, dpi2->height + dpi2->y - 1, weather_colour);
|
||||
}
|
||||
|
|
|
@ -199,6 +199,9 @@ void climate_force_weather(uint8 weather){
|
|||
RCT2_GLOBAL(RCT2_ADDRESS_CLIMATE_UPDATE_TIMER, sint16) = 1920;
|
||||
|
||||
climate_update();
|
||||
|
||||
// Incase of change in gloom level force a complete redraw
|
||||
gfx_invalidate_screen();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue