mirror of
https://gitlab.com/MaddoScientisto/cirnogodot.git
synced 2026-06-10 06:25:54 +00:00
New Fairies
This commit is contained in:
parent
54c8199e8a
commit
ce4df42890
11 changed files with 253 additions and 53 deletions
|
|
@ -6,7 +6,10 @@ using Godot;
|
|||
public partial class Actor : CharacterBody2D
|
||||
{
|
||||
[Export]
|
||||
public float MovementSpeed { get; private set; }
|
||||
public float MovementSpeed { get; private set; } = 20f;
|
||||
|
||||
[Export]
|
||||
public float Health { get; private set; } = 4f;
|
||||
|
||||
[ExportCategory("Defeat Script")]
|
||||
[Export] public Node2D DefeatScript { get; set; }
|
||||
|
|
|
|||
|
|
@ -18,6 +18,8 @@ public partial class DamageReceiverActorModule : ActorModule
|
|||
{
|
||||
_actor = actor;
|
||||
|
||||
this.HealthProvider.MaxResource = actor.Health;
|
||||
|
||||
HealthProvider.FillResource();
|
||||
HealthProvider.ResourceDepleted += OnDeath;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue