Files
the-connection/client/Scripts/Component/Savebox.gd

9 lines
165 B
GDScript

extends Area2D
func _ready():
connect("body_entered", self, "_on_body_entered")
func _on_body_entered(body):
if body.saved_pos:
body.saved_pos = body.position