How can I move node C to the sub node of the master without deleting the node in the code?
Thanks.
How can I move node to sub node in SceneTree
Asked Answered
Charade There's also reparent()
$b/c.reparent($a)
Charade Remove the node then add it back wherever you'd like
var c: Node = $"b/c"
$b.remove_child(c)
add_child(c)
This removes the node from b
and adds it back as a child of master
Charade There's also reparent()
$b/c.reparent($a)
© 2022 - 2024 — McMap. All rights reserved.