Fix CanBuild not checking DeveloperMode.AllTech.

This commit is contained in:
Paul Chote
2014-06-21 22:22:23 +12:00
parent 749a947d3f
commit 4b2663015b

View File

@@ -220,7 +220,11 @@ namespace OpenRA.Mods.RA
public bool CanBuild(ActorInfo actor)
{
return produceable.ContainsKey(actor) && produceable[actor].Buildable;
ProductionState ps;
if (!produceable.TryGetValue(actor, out ps))
return false;
return ps.Buildable || (self.World.AllowDevCommands && developerMode.AllTech);
}
public virtual void Tick(Actor self)