1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-19 13:03:11 +01:00

Set viewport location immediately, fixes rotation using stale position

This commit is contained in:
ζeh Matt
2025-04-25 17:23:43 +03:00
parent 7aca569363
commit 8503faa289
2 changed files with 66 additions and 56 deletions

View File

@@ -12,6 +12,12 @@ namespace OpenRCT2
{
WindowScrollToLocation(*this, coords);
flags &= ~WF_SCROLLING_TO_LOCATION;
// Immediately update the viewport position since we are not scrolling.
if (viewport != nullptr)
{
viewport->viewPos = savedViewPos;
}
}
void WindowBase::Invalidate()