When zooming using the mousewheel, zoom towards the pointer location.

This commit is contained in:
Andre Mohren
2020-07-14 17:17:05 +02:00
committed by Oliver Brakmann
parent b417b267dd
commit 914950c4a5
3 changed files with 10 additions and 2 deletions

View File

@@ -87,7 +87,7 @@ namespace OpenRA.Mods.Common.Widgets
{
if (mi.Event == MouseInputEvent.Scroll && mi.Modifiers.HasModifier(Game.Settings.Game.ZoomModifier))
{
worldRenderer.Viewport.AdjustZoom(mi.Delta.Y * Game.Settings.Game.ZoomSpeed);
worldRenderer.Viewport.AdjustZoom(mi.Delta.Y * Game.Settings.Game.ZoomSpeed, mi.Location);
return true;
}