Draw border around capture area in ProximityCapturable

This commit is contained in:
Oliver Brakmann
2020-02-29 17:03:47 +01:00
committed by Paul Chote
parent c4acd8b361
commit 3904576574
3 changed files with 33 additions and 1 deletions

View File

@@ -9,6 +9,10 @@
*/
#endregion
using OpenRA.Graphics;
using OpenRA.Mods.Common.Graphics;
using OpenRA.Primitives;
namespace OpenRA.Mods.Common.Traits
{
[Desc("Actor can be captured by units within a certain range.")]
@@ -44,5 +48,10 @@ namespace OpenRA.Mods.Common.Traits
{
self.World.ActorMap.UpdateProximityTrigger(trigger, self.CenterPosition, Info.Range, WDist.Zero);
}
protected override IRenderable GetRenderable(Actor self, WorldRenderer wr)
{
return new RangeCircleAnnotationRenderable(self.CenterPosition, Info.Range, 0, self.Owner.Color, 1, Color.Black, 3);
}
}
}