12 lines
186 B
GDScript
12 lines
186 B
GDScript
class_name SkillsComponent
|
|
extends Node
|
|
|
|
var player: Player
|
|
|
|
func _ready():
|
|
player = owner
|
|
player.attacked.connect(attack)
|
|
|
|
func attack():
|
|
%Health.take_damage(DamageInstance.new(10))
|