GrappleTest/Objects/AnimTrigger/AnimTrigger.gd
2024-03-13 16:15:55 -05:00

10 lines
247 B
GDScript

extends Area2D
@export var animator : AnimationPlayer
@export var animation : String
@export var playOnce := true
var animReady = false
func _on_body_shape_entered(body_rid, body, body_shape_index, local_shape_index):
animator.play(animation)