aboutsummaryrefslogblamecommitdiffstats
path: root/Scripts/Checkpoint.gd
blob: 119419a01c4dc0745bd8f6d30c6cc69d53d2da6e (plain) (tree)
1
2
3
4
5
6
7
8




                       


                                    



                                         

                                    
extends Node2D


var was_visited = false


func set_was_visited(visited: bool):
	was_visited = visited
	$Sprite2Dclosed.visible = visited
	$Sprite2Dopen.visible = !visited
	
	
func _on_area_2d_body_entered(body):
	set_was_visited(true)