Introduce World.LocalShroud. Breaks targeting stealth tanks. Probably breaks FrozenUnderFog.
This commit is contained in:
@@ -73,19 +73,13 @@ namespace OpenRA.Mods.RA
|
||||
Color trailEnd = Color.FromArgb(trailStart.A - 255 / TrailLength, trailStart.R,
|
||||
trailStart.G, trailStart.B);
|
||||
|
||||
// LocalPlayer is null on shellmap
|
||||
Shroud shroud = null;
|
||||
if (self.World.LocalPlayer != null)
|
||||
shroud = self.World.LocalPlayer.Shroud;
|
||||
|
||||
for (int i = positions.Count - 1; i >= 1; --i)
|
||||
{
|
||||
var conPos = positions[i];
|
||||
var nextPos = positions[i - 1];
|
||||
|
||||
if (shroud == null ||
|
||||
shroud.IsVisible(OpenRA.Traits.Util.CellContaining(conPos)) ||
|
||||
shroud.IsVisible(OpenRA.Traits.Util.CellContaining(nextPos)))
|
||||
if (self.World.LocalShroud.IsVisible(OpenRA.Traits.Util.CellContaining(conPos)) ||
|
||||
self.World.LocalShroud.IsVisible(OpenRA.Traits.Util.CellContaining(nextPos)))
|
||||
{
|
||||
Game.Renderer.LineRenderer.DrawLine(conPos, nextPos, trailStart, trailEnd);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user