used DI for forge managers where possible

This commit is contained in:
2026-04-28 16:34:10 +02:00
parent ec44306d48
commit 24f057c15f
8 changed files with 129 additions and 112 deletions

View File

@@ -8,7 +8,7 @@ using Gamesmiths.Forge.Cues;
using Gamesmiths.Forge.Godot.Core;
using Gamesmiths.Forge.Tags;
[GlobalClass, Icon("res://assets/ui/IconGodotNode/control/icon_heart.png"), Meta(typeof(IAutoOn), typeof(IAutoConnect))]
[GlobalClass, Icon("res://assets/ui/IconGodotNode/control/icon_heart.png"), Meta(typeof(IAutoNode))]
public partial class ResourceBar : ProgressBar, ICueHandler
{
public override void _Notification(int what) => this.Notify(what);
@@ -33,8 +33,8 @@ public partial class ResourceBar : ProgressBar, ICueHandler
if (BarStyle != null)
AddThemeStyleboxOverride("fill", BarStyle);
}
public void Initialize(EntityAttribute attribute, Tag cueTag)
public void Init(EntityAttribute attribute, Tag cueTag)
{
_currentValue = attribute.BaseValue;
MaxValue = attribute.Max;