0 votes

How one would go about hiding a node that has a Canvas Layer in it?

I am only able to use them as a root? If so, it should not show options for visibility, only confuses when you try to switch it off, and nothing happens.

asked Nov 10, 2019 in Engine by The_Black_Chess_King (265 points)
edited Nov 11, 2019 by The_Black_Chess_King

1 Answer

+1 vote
Best answer

$CanvasLayer.get_child(0).hide()

Always have a sub parent for your GUI like control node

I personally also use canvas layer as a root for my GUI, as it makes instancing a lot easier and gives me control on the z-axis

answered Nov 11, 2019 by LoneDespair (317 points)
selected Nov 11, 2019 by The_Black_Chess_King
Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read How to use this Q&A? before posting your first questions.