Hide() and Show() not working for non-child nodes

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

Ok, so I has a hierarchy like this:
->Panel—V (has my sript)
------------->Enter (On click condition)

Thing is A.hide(), A.show() is working well with other stuf (for child nodes)
It doesn’t work for path nodes:

func EnterLand():
var B1 = $“/root/Map/Map_Geo”
var B2 = $“/root/Map/Map_Counties”
var B3 = $“/root/Map/Map_Culture”
var B4 = $“/root/Map/Heraldics_of_counties”

func _on_Enter_pressed():

I was trying to check if something is wrong with a script but as I see from print I get the right nodes:


So I can not use hide(), show() for non-child nodes? Since I tried it and it works well if I lunch it from Map’s script (which is my main root).

Also, I wanted to ask if this engine has data analitic functions? Since I’m a Math student I see it as super tool to show data and so on… If it does have something similiar like R does for plots or calculations that would become top tool.

And thanks for all help I might get :slight_smile:

If I’m not mistaken, the draw function is only called on nodes in the scene tree. Consider adding your “path nodes” to the hierarchy via parent.add_child(node_you_wish_to_add) (or add_child(node) in the parent node’s script.)

DDoop | 2020-06-26 20:56