From e60acc682a3948b256a320b96b40b953dfc21311 Mon Sep 17 00:00:00 2001 From: Chris Forbes Date: Wed, 9 Jun 2010 20:36:36 +1200 Subject: [PATCH] add logging to ProductionItem --- OpenRA.Game/Traits/Player/ProductionQueue.cs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/OpenRA.Game/Traits/Player/ProductionQueue.cs b/OpenRA.Game/Traits/Player/ProductionQueue.cs index a7a5886940..85f010effc 100644 --- a/OpenRA.Game/Traits/Player/ProductionQueue.cs +++ b/OpenRA.Game/Traits/Player/ProductionQueue.cs @@ -123,7 +123,7 @@ namespace OpenRA.Traits return production[category]; } - public void CancelProduction( string itemName ) + void CancelProduction( string itemName ) { var category = Rules.Info[itemName].Category; var queue = production[ category ]; @@ -214,12 +214,13 @@ namespace OpenRA.Traits public ProductionItem(string item, int time, int cost, Action onComplete) { - if (time <= 0) - time = 1; + if (time <= 0) time = 1; Item = item; RemainingTime = TotalTime = time; RemainingCost = TotalCost = cost; OnComplete = onComplete; + + Log.Write("new ProductionItem: {0} time={1} cost={2}", item, time, cost); } public void Tick(Player player)