paratate/objects/bosses/tesu.gd
pennyrigate d729c0a7a3 hud
2025-12-30 19:33:18 -05:00

15 lines
436 B
GDScript

extends Node2D
var health = 100.0
func _on_area_2d_area_entered(area: Area2D) -> void:
CurrentGame.change_score(100)
%HurtSound.play()
health -= 0.25
print(%Movements.current_animation)
if health < 50.0 && health >= 25.0 && %Movements.current_animation != "midway_left":
%Movements.play("midway_left")
if health < 25.0 && %Movements.current_animation != "pinch":
%Movements.play("pinch")
%AnimationPlayer.play("hurt")