mirror of
https://github.com/godotengine/godot.git
synced 2025-02-17 16:20:53 +00:00
Updated tutorial_singletons (markdown)
parent
dd7ab041e7
commit
49135cb3c9
@ -80,7 +80,7 @@ Next, is the function for changing scene. This function will erase the current s
|
||||
|
||||
func goto_scene(scene):
|
||||
# remove current scene from root and enqueue it for deletion
|
||||
get_tree().get_root().remove(current_scene)
|
||||
get_tree().get_root().remove_child(current_scene)
|
||||
current_scene.queue_free()
|
||||
|
||||
# load and add new scene to root
|
||||
|
Loading…
Reference in New Issue
Block a user