lots of features

This commit is contained in:
2023-08-04 11:30:18 -07:00
parent d098cfb017
commit 339cb374b8
27 changed files with 427 additions and 36 deletions

View File

@@ -7,7 +7,7 @@ public partial class Target : StaticBody3D
private int _currentHP;
[Export]
private ProgressBar _progressBar;
private Healthbar _progressBar;
public override void _Ready()
{
@@ -18,7 +18,7 @@ public partial class Target : StaticBody3D
{
_currentHP -= damage;
GD.Print($"Current HP: {_currentHP}");
_progressBar.Value = _currentHP;
_progressBar.Update(_currentHP, _maxHP);
if (_currentHP <= 0)
QueueFree();