How i can make Label (from canvaslayer) visible from the other scene (Player)?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Spaliasum

I got CanvasLayer with label (i wrote “Game over” in it") (it is one scene) and i got scene “Player”. When player is falling out of a map, i want to make the lable (from canvaslayer scene) visible. So how i can change visible/invisible for this label from the other scene (Player)? Thanks.

:bust_in_silhouette: Reply From: Asthmar

You can do two things

  1. Instance the “Game over” Canvas layer into the player scene, and hide it. Only show it whenever you need too

  2. Make your “Game over” Canvas layer an singleton scene. Meaning it will always be open. So you would hide it and only show when needed. More on singletons here : Singletons (Autoload) — Godot Engine (stable) documentation in English