Prepare DeveloperMode code for trait-defined lobby options.

This commit is contained in:
Paul Chote
2016-04-20 09:20:42 +02:00
parent 1eba0bea13
commit 7e49ae7eb0
6 changed files with 134 additions and 117 deletions

View File

@@ -125,7 +125,7 @@ namespace OpenRA.Mods.Common.Traits
public override int GetBuildTime(ActorInfo unit, BuildableInfo bi = null)
{
if (self.World.AllowDevCommands && self.Owner.PlayerActor.Trait<DeveloperMode>().FastBuild)
if (developerMode.FastBuild)
return 0;
var time = unit.GetBuildTime() * Info.BuildSpeed / 100;