fix crash in CrateEffect

This commit is contained in:
Chris Forbes
2010-10-09 12:01:19 +13:00
parent 580f1cfe97
commit e3d71acb05

View File

@@ -41,8 +41,9 @@ namespace OpenRA.Mods.RA.Effects
public IEnumerable<Renderable> Render()
{
yield return new Renderable(anim.Image,
a.CenterLocation - .5f * anim.Image.size + offset, "effect", (int)a.CenterLocation.Y);
if (a.IsInWorld)
yield return new Renderable(anim.Image,
a.CenterLocation - .5f * anim.Image.size + offset, "effect", (int)a.CenterLocation.Y);
}
}
}