Update viewport positions in two stages

This commit is contained in:
Jonathan G Rennison
2023-09-18 20:25:05 +01:00
parent 96ed5b5cad
commit 290822d150
5 changed files with 39 additions and 18 deletions

View File

@@ -3365,11 +3365,16 @@ void UpdateWindows()
}
}
for (Window *w : Window::Iterate()) {
/* Update viewport only if window is not shaded. */
if (w->viewport != nullptr && !w->IsShaded()) UpdateNextViewportPosition(w);
}
DrawDirtyBlocks();
for (Window *w : Window::Iterate()) {
/* Update viewport only if window is not shaded. */
if (w->viewport != nullptr && !w->IsShaded()) UpdateViewportPosition(w);
if (w->viewport != nullptr && !w->IsShaded()) ApplyNextViewportPosition(w);
}
ViewportDoDrawProcessAllPending();
NetworkDrawChatMessage();