Use the standard radar shroud updating when switching to observer.

This commit is contained in:
Paul Chote
2015-07-05 11:14:59 +01:00
parent a77e0782cf
commit f1e6f01e44

View File

@@ -290,15 +290,12 @@ namespace OpenRA.Mods.Common.Widgets
if (newRenderShroud != null) if (newRenderShroud != null)
{ {
// Redraw the full shroud sprite // Redraw the full shroud sprite
using (var bitmap = Minimap.ShroudBitmap(world)) MarkShroudDirty(world.Map.CellsInsideBounds);
OpenRA.Graphics.Util.FastCopyIntoSprite(shroudSprite, bitmap);
// Update the notification binding // Update the notification binding
newRenderShroud.CellsChanged += MarkShroudDirty; newRenderShroud.CellsChanged += MarkShroudDirty;
} }
dirtyShroudCells.Clear();
renderShroud = newRenderShroud; renderShroud = newRenderShroud;
} }