The alternative way to check if player has fallen to death

Using Godot’s VisibilityNotifier2D you don’t have to check if player has fallen to death with if checks when falling. You just connect a signal screen_exited in Player.

kuva

kuva

func _on_VisibilityNotifier2D_screen_exited():
    get_tree().change_scene("res://Scenes/GameOver.tscn")
1 Like

Privacy & Terms