diff --git a/OpenRA.Game/OpenRA.Game.csproj b/OpenRA.Game/OpenRA.Game.csproj
index c9ce38357a..58a528739f 100755
--- a/OpenRA.Game/OpenRA.Game.csproj
+++ b/OpenRA.Game/OpenRA.Game.csproj
@@ -94,7 +94,6 @@
-
diff --git a/OpenRA.Game/Traits/Player/ProductionQueue.cs b/OpenRA.Game/Traits/Player/ProductionQueue.cs
index 6c027c0e2c..c99c736b09 100644
--- a/OpenRA.Game/Traits/Player/ProductionQueue.cs
+++ b/OpenRA.Game/Traits/Player/ProductionQueue.cs
@@ -27,6 +27,8 @@ namespace OpenRA.Traits
{
class ProductionQueueInfo : ITraitInfo
{
+ public readonly float BuildSpeed = 0.4f;
+ public readonly int LowPowerSlowdown = 3;
public object Create(Actor self) { return new ProductionQueue(self); }
}
@@ -57,7 +59,7 @@ namespace OpenRA.Traits
var unit = Rules.Info[order.TargetString];
var ui = unit.Traits.Get();
var time = ui.Cost
- * self.World.Defaults.BuildSpeed /* todo: country-specific build speed bonus */
+ * self.Owner.PlayerActor.Info.Traits.Get().BuildSpeed /* todo: country-specific build speed bonus */
* (25 * 60) /* frames per min */ /* todo: build acceleration, if we do that */
/ 1000;
@@ -192,7 +194,7 @@ namespace OpenRA.Traits
class ProductionItem
{
public readonly string Item;
-
+
public readonly int TotalTime;
public readonly int TotalCost;
public int RemainingTime { get; private set; }
@@ -226,14 +228,13 @@ namespace OpenRA.Traits
if (player.GetPowerState() != PowerState.Normal)
{
if (--slowdown <= 0)
- slowdown = player.World.Defaults.LowPowerSlowdown;
+ slowdown = player.PlayerActor.Info.Traits.Get().LowPowerSlowdown;
else
return;
}
var costThisFrame = RemainingCost / RemainingTime;
if (costThisFrame != 0 && !player.TakeCash(costThisFrame)) return;
-
RemainingCost -= costThisFrame;
RemainingTime -= 1;
if (RemainingTime > 0) return;
diff --git a/OpenRA.Game/Traits/World/GlobalDefaults.cs b/OpenRA.Game/Traits/World/GlobalDefaults.cs
index 6548f3b97c..38c3a4716a 100644
--- a/OpenRA.Game/Traits/World/GlobalDefaults.cs
+++ b/OpenRA.Game/Traits/World/GlobalDefaults.cs
@@ -42,7 +42,6 @@ namespace OpenRA.Traits
public readonly int Incoming = 10;
/* Income & Production */
- public readonly float BuildSpeed = 0.4f;
public readonly float BuildupTime = 0.06f;
public readonly float OreTruckRate = 1;
public readonly bool SeparateAircraft = false;
@@ -75,12 +74,9 @@ namespace OpenRA.Traits
public readonly int LZScanRadius = 16;
public readonly bool MineAware = true;
public readonly float Stray = 2.0f;
- public readonly float SubmergeDelay = 0.02f;
public readonly float SuspendDelay = 2.0f;
public readonly int SuspendPriority = 20;
public readonly float TeamDelay = 0.6f;
-
- public readonly int LowPowerSlowdown = 3;
}
public class GlobalDefaults {}
diff --git a/mods/cnc/system.yaml b/mods/cnc/system.yaml
index 9f48334af0..b9ef559642 100644
--- a/mods/cnc/system.yaml
+++ b/mods/cnc/system.yaml
@@ -1,5 +1,7 @@
Player:
ProductionQueue:
+ BuildSpeed: .4
+ LowPowerSlowdown: 3
PlaceBuilding:
NukePower:
Image: atomicnh
diff --git a/mods/ra/rules.yaml b/mods/ra/rules.yaml
index 2ac4fc32ab..c8f3c966a9 100755
--- a/mods/ra/rules.yaml
+++ b/mods/ra/rules.yaml
@@ -1,5 +1,7 @@
Player:
ProductionQueue:
+ BuildSpeed: .4
+ LowPowerSlowdown: 3
PlaceBuilding:
GpsPower:
Image: gpssicon