Fixed bug where unit would occasionally "disappear" or face in an odd direction.

This commit is contained in:
Bob
2009-10-24 20:48:36 +13:00
parent f6ae86bb53
commit 5086f6ab51
4 changed files with 47 additions and 48 deletions

View File

@@ -59,14 +59,14 @@ namespace OpenRa.Game
}
public void Build(SidebarItem item)
{
if (item != null)
{
if (item.techTreeItem.IsStructure)
Game.controller.orderGenerator = new PlaceBuilding(Game.LocalPlayer,
item.techTreeItem.tag.ToLowerInvariant());
else
Game.BuildUnit(Game.LocalPlayer, item.techTreeItem.tag.ToLowerInvariant());
{
if (item != null)
{
if (item.techTreeItem.IsStructure)
Game.controller.orderGenerator = new PlaceBuilding(Game.LocalPlayer,
item.techTreeItem.tag.ToLowerInvariant());
else
Game.BuildUnit(Game.LocalPlayer, item.techTreeItem.tag.ToLowerInvariant());
}
}