From f17e0eec75f3532b521956a373723207520939d6 Mon Sep 17 00:00:00 2001 From: Chris Forbes Date: Fri, 23 Oct 2009 21:14:32 +1300 Subject: [PATCH] move-blocked cursor is now used for impossible moves --- OpenRa.Game/Controller.cs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/OpenRa.Game/Controller.cs b/OpenRa.Game/Controller.cs index e94c2f0be0..ef0b8d2b70 100644 --- a/OpenRa.Game/Controller.cs +++ b/OpenRa.Game/Controller.cs @@ -72,7 +72,11 @@ namespace OpenRa.Game var uog = orderGenerator as UnitOrderGenerator; if (uog != null && uog.selection.Count > 0 && uog.selection.Any(a => a.traits.Contains())) + { + if (!Game.IsCellBuildable(dragEnd.ToInt2(), UnitMovementType.Wheel)) + return Cursor.MoveBlocked; /* todo: handle non-wheel movement behavior */ return Cursor.Move; + } if (Game.SelectUnitOrBuilding(Game.CellSize * dragEnd).Any()) return Cursor.Select;