Make support power icons configurable and testable.

This commit is contained in:
Matthias Mailänder
2020-03-21 11:57:52 +01:00
committed by atlimit8
parent 85096c4ba2
commit d187575a2c
3 changed files with 13 additions and 7 deletions

View File

@@ -98,7 +98,6 @@ namespace OpenRA.Mods.Common.Widgets
tooltipContainer = Exts.Lazy(() =>
Ui.Root.Get<TooltipContainerWidget>(TooltipContainer));
icon = new Animation(world, "icon");
clock = new Animation(world, ClockAnimation);
}
@@ -138,6 +137,7 @@ namespace OpenRA.Mods.Common.Widgets
else
rect = new Rectangle(rb.X, rb.Y + IconCount * (IconSize.Y + IconMargin), IconSize.X, IconSize.Y);
icon = new Animation(worldRenderer.World, p.Info.IconImage);
icon.Play(p.Info.Icon);
var power = new SupportPowerIcon()