GodotCourse/week2/updated_files/scripts/Trigger.gd
2024-09-09 13:12:01 -04:00

9 lines
168 B
GDScript

extends Area2D
@export var effect = "alert"
signal areatrigger(effect, Object)
func _on_body_entered(body):
print("detected a body")
areatrigger.emit(effect, body)