GrappleTest/Objects/SceneTeleporter/teleportergd.gd

10 lines
261 B
GDScript3
Raw Normal View History

2024-03-13 16:15:55 -05:00
extends Node2D
@export var scenePath := "res://"
func _ready():
ResourceLoader.load_threaded_request(scenePath)
func _on_collision_detector_body_shape_entered(body_rid, body, body_shape_index, local_shape_index):
get_tree().change_scene_to_file(scenePath)