Fix observer tooltips (Bug #769)

This commit is contained in:
Paul Chote
2011-06-21 02:51:50 +12:00
parent e33995d71b
commit ce65127e34
2 changed files with 3 additions and 3 deletions

View File

@@ -29,13 +29,13 @@ namespace OpenRA.Mods.RA.Widgets
public override void DrawInner()
{
if (Viewport.TicksSinceLastMove < TooltipDelay || world == null || world.LocalPlayer == null)
if (Viewport.TicksSinceLastMove < TooltipDelay || world == null)
return;
var cell = Game.viewport.ViewToWorld(Viewport.LastMousePos).ToInt2();
if (!world.Map.IsInMap(cell)) return;
if (!world.LocalPlayer.Shroud.IsExplored(cell))
if (world.LocalPlayer != null && !world.LocalPlayer.Shroud.IsExplored(cell))
{
var utext = "Unexplored Terrain";
var usz = Game.Renderer.Fonts["Bold"].Measure(utext) + new int2(20, 24);