Convert CombatDebugOverlay to IRenderAboveShroud.
This commit is contained in:
@@ -10,6 +10,7 @@
|
||||
#endregion
|
||||
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using OpenRA.Graphics;
|
||||
using OpenRA.Mods.Common.Graphics;
|
||||
using OpenRA.Primitives;
|
||||
@@ -57,14 +58,11 @@ namespace OpenRA.Mods.Common.HitShapes
|
||||
return DistanceFromEdge(pos - new WPos(actorPos.X, actorPos.Y, pos.Z));
|
||||
}
|
||||
|
||||
public void DrawCombatOverlay(WorldRenderer wr, RgbaColorRenderer wcr, Actor actor)
|
||||
IEnumerable<IRenderable> IHitShape.RenderDebugOverlay(WorldRenderer wr, Actor actor)
|
||||
{
|
||||
var actorPos = actor.CenterPosition;
|
||||
|
||||
RangeCircleRenderable.DrawRangeCircle(
|
||||
wr, actorPos + new WVec(0, 0, VerticalTopOffset), Radius, 1, Color.Yellow, 0, Color.Yellow);
|
||||
RangeCircleRenderable.DrawRangeCircle(
|
||||
wr, actorPos + new WVec(0, 0, VerticalBottomOffset), Radius, 1, Color.Yellow, 0, Color.Yellow);
|
||||
yield return new CircleAnnotationRenderable(actorPos + new WVec(0, 0, VerticalTopOffset), Radius, 1, Color.Yellow);
|
||||
yield return new CircleAnnotationRenderable(actorPos + new WVec(0, 0, VerticalBottomOffset), Radius, 1, Color.Yellow);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user