I am trying to switch the scene after the screen fades to black.
`extends TextureButton
onready var anim = $Fade/AnimationPlayer
func _process(delta):
if Input.is_action_just_pressed("mouseleft"):
anim.play("fadeblack")
anim.connect("animation_finished", self ,"_on_animation_finish")
func _on_animation_finish():
get_tree().change_scene("res://Node2D.tscn")`