dora/Goal.gd
2018-07-19 15:37:14 +02:00

8 lines
168 B
GDScript

extends Spatial
func _ready():
get_node("Area").connect("body_entered", self, "collided")
func collided(body):
if body.has_method("reach_goal"):
body.reach_goal()