Make Harvester conditional.
This commit is contained in:
committed by
abcdefg30
parent
cd90c70cdf
commit
dcb70d12e3
@@ -407,7 +407,7 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
||||
template.Get<LabelWidget>("ASSETS").GetText = () => assetsText.Update(stats.AssetsValue);
|
||||
|
||||
var harvesters = template.Get<LabelWidget>("HARVESTERS");
|
||||
harvesters.GetText = () => world.ActorsHavingTrait<Harvester>().Count(a => a.Owner == player && !a.IsDead).ToString();
|
||||
harvesters.GetText = () => world.ActorsWithTrait<Harvester>().Count(a => a.Actor.Owner == player && !a.Actor.IsDead && !a.Trait.IsTraitDisabled).ToString();
|
||||
|
||||
var derricks = template.GetOrNull<LabelWidget>("DERRICKS");
|
||||
if (derricks != null)
|
||||
|
||||
Reference in New Issue
Block a user