diff --git a/OpenRA.Mods.Common/Traits/AttackMove.cs b/OpenRA.Mods.Common/Traits/AttackMove.cs index ba58208cf7..aacdf7fb98 100644 --- a/OpenRA.Mods.Common/Traits/AttackMove.cs +++ b/OpenRA.Mods.Common/Traits/AttackMove.cs @@ -31,6 +31,9 @@ namespace OpenRA.Mods.Common.Traits [Desc("The condition to grant to self while scanning for targets during an assault-move.")] public readonly string AssaultMoveScanCondition = null; + [Desc("Can the actor be ordered to move in to shroud?")] + public readonly bool MoveIntoShroud = true; + public object Create(ActorInitializer init) { return new AttackMove(init.Self, this); } } @@ -108,6 +111,9 @@ namespace OpenRA.Mods.Common.Traits if (!order.Queued) self.CancelActivity(); + if (!info.MoveIntoShroud && !self.Owner.Shroud.IsExplored(order.TargetLocation)) + return; + TargetLocation = move.NearestMoveableCell(order.TargetLocation); self.SetTargetLine(Target.FromCell(self.World, TargetLocation.Value), Color.Red); Activate(self, order.OrderString == "AssaultMove"); diff --git a/mods/ts/rules/defaults.yaml b/mods/ts/rules/defaults.yaml index 0644906722..aa69d48deb 100644 --- a/mods/ts/rules/defaults.yaml +++ b/mods/ts/rules/defaults.yaml @@ -824,6 +824,7 @@ Type: GroundPosition AttackMove: Voice: Move + MoveIntoShroud: false ActorLostNotification: BodyOrientation: QuantizedFacings: 0