Allow beacons to be placed and drawn above the shroud.

This commit is contained in:
Paul Chote
2016-08-22 16:18:54 +01:00
parent afdb0e0829
commit b016638ebe
3 changed files with 15 additions and 16 deletions

View File

@@ -18,13 +18,8 @@ namespace OpenRA.Mods.Common.Orders
{
public IEnumerable<Order> Order(World world, CPos cell, int2 worldPixel, MouseInput mi)
{
if (mi.Button != MouseButton.Left)
world.CancelInputMode();
else if (!world.ShroudObscures(cell))
{
world.CancelInputMode();
yield return new Order("PlaceBeacon", world.LocalPlayer.PlayerActor, false) { TargetLocation = cell, SuppressVisualFeedback = true };
}
world.CancelInputMode();
yield return new Order("PlaceBeacon", world.LocalPlayer.PlayerActor, false) { TargetLocation = cell, SuppressVisualFeedback = true };
}
public virtual void Tick(World world) { }
@@ -32,7 +27,7 @@ namespace OpenRA.Mods.Common.Orders
public IEnumerable<IRenderable> RenderAfterWorld(WorldRenderer wr, World world) { yield break; }
public string GetCursor(World world, CPos cell, int2 worldPixel, MouseInput mi)
{
return !world.ShroudObscures(cell) ? "ability" : "generic-blocked";
return "ability";
}
}
}