From 23ea8493ba785ce895f4c82f65eb0809633f7757 Mon Sep 17 00:00:00 2001 From: Chris Forbes Date: Fri, 16 Mar 2012 18:38:45 +1300 Subject: [PATCH] fix crash in cnc replay viewing with radar --- OpenRA.Mods.RA/Widgets/RadarWidget.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/OpenRA.Mods.RA/Widgets/RadarWidget.cs b/OpenRA.Mods.RA/Widgets/RadarWidget.cs index c4698d94cc..72830d5e92 100755 --- a/OpenRA.Mods.RA/Widgets/RadarWidget.cs +++ b/OpenRA.Mods.RA/Widgets/RadarWidget.cs @@ -128,7 +128,7 @@ namespace OpenRA.Mods.RA.Widgets public override void Draw() { if (world == null) return; - if( world.LocalPlayer.WinState != WinState.Undefined ) return; + if (world.LocalPlayer != null && world.LocalPlayer.WinState != WinState.Undefined) return; var o = new float2(mapRect.Location.X, mapRect.Location.Y + world.Map.Bounds.Height * previewScale * (1 - radarMinimapHeight)/2); var s = new float2(mapRect.Size.Width, mapRect.Size.Height*radarMinimapHeight);