Improved component system
This commit is contained in:
@ -9,7 +9,7 @@ var health: HealthComponent
|
||||
func _ready():
|
||||
health = owner.health
|
||||
health.value_changed.connect(on_health_changed)
|
||||
|
||||
|
||||
func on_health_changed():
|
||||
value = health.value / health.max_value
|
||||
|
||||
|
Reference in New Issue
Block a user