Godot Version
Godot-3
Question
So I can use signals for other nodes in a scene. Now, what if I want to send a signal to a separate scene. It doesn’t allow me to what do I do?
Godot-3
So I can use signals for other nodes in a scene. Now, what if I want to send a signal to a separate scene. It doesn’t allow me to what do I do?
It depends on what you mean. When you are running the game. There’s just one scene tree at any point in time, so any active notes are in the same tree.
If you have a scene you’ve made and you want other scenes which include scene as a node, then you can make that scene have whatever signals you want. When you load that scene as a node in another scene (either through the editor or through code), you can then connect to those signals. The script for the root node of that scene can act as a “middle man” for any other nodes internal to that scene and any other scene that uses it.
Yeah, you aren’t in that scene, so it doesn’t have to happen at the same time. You can have a global variable and check it in the ready function of the new scene when it opens.
thx for telling me that