Introduce Order.SuppressVisualFeedback to cleanly disable flashes.

This commit is contained in:
Paul Chote
2014-06-21 22:05:36 +12:00
parent 32e0bf3edf
commit 7d24053f52
12 changed files with 22 additions and 15 deletions

View File

@@ -23,7 +23,7 @@ namespace OpenRA.Mods.RA.Orders
if (!world.ShroudObscures(xy))
{
world.CancelInputMode();
yield return new Order("PlaceBeacon", world.LocalPlayer.PlayerActor, false) { TargetLocation = xy };
yield return new Order("PlaceBeacon", world.LocalPlayer.PlayerActor, false) { TargetLocation = xy, SuppressVisualFeedback = true };
}
}

View File

@@ -62,8 +62,12 @@ namespace OpenRA.Mods.RA.Orders
}
var isLineBuild = world.Map.Rules.Actors[Building].Traits.Contains<LineBuildInfo>();
yield return new Order(isLineBuild ? "LineBuild" : "PlaceBuilding",
Producer.Owner.PlayerActor, false) { TargetLocation = topLeft, TargetString = Building };
yield return new Order(isLineBuild ? "LineBuild" : "PlaceBuilding", Producer.Owner.PlayerActor, false)
{
TargetLocation = topLeft,
TargetString = Building,
SuppressVisualFeedback = true
};
}
}