Hi.
I'm trying to access a uniquely named node but am having trouble doing so. Here is a screenshot of my scene tree:
The node in question is 'AllDestructibles'. So this scene is composed of other scenes and the script that is trying to access AllDestructibles is attached to a node inside the 'Lander' scene where I'm doing this:
var all_destructibles = %AllDestructibles
. However that just ends up being null.
If I create a unique 'AllDestructibles' node attached to the Lander scene, then it works. Why can I not access this unique node from a script inside another scene? Is that just not possible?
I am able to get this to work if, instead, I do something like get_tree().get_root().find_child("AllDestructibles", true, false)
. So I'm mostly asking this just to understand things better.
Thanks!