Don’t display LaserZap if source and dest are hidden.

Closes #6146.
This commit is contained in:
Paul Chote
2014-08-23 09:47:46 +12:00
parent 6fcd4c3605
commit fc6d266278

View File

@@ -82,6 +82,10 @@ namespace OpenRA.Mods.RA.Effects
public IEnumerable<IRenderable> Render(WorldRenderer wr)
{
if (wr.world.FogObscures(wr.world.Map.CellContaining(target)) &&
wr.world.FogObscures(wr.world.Map.CellContaining(args.Source)))
yield break;
if (ticks < info.BeamDuration)
{
var rc = Color.FromArgb((info.BeamDuration - ticks) * 255 / info.BeamDuration, color);