1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-17 20:13:07 +01:00

Fix #2607: Rain rendered incorrectly in additional viewport

This commit is contained in:
Hielke Morsink
2017-12-08 11:24:45 +01:00
committed by Michael Steenbeek
parent e307d22bf9
commit 40cea0e7e7
2 changed files with 5 additions and 4 deletions

View File

@@ -59,10 +59,10 @@ static void CallDrawRainFunc(IRainDrawer * rainDrawer,
return;
}
left = Math::Max(left, vp->x);
right = Math::Min(right, vp->width);
top = Math::Max(top, vp->y);
bottom = Math::Min(bottom, vp->height);
left = Math::Max<sint16>(left, vp->x);
right = Math::Min<sint16>(right, vp->x + vp->width);
top = Math::Max<sint16>(top, vp->y);
bottom = Math::Min<sint16>(bottom, vp->y + vp->height);
if (left >= right || top >= bottom)
{
return;