How to move a node?

Godot Version

Godot 4

Question

Hi, how to move nodes in Godot by script?
Moving
I want to move nodes when something happend, but how to do this?

All nodes have a “reparent” method you can use to reparent a node, which should shift where it is in the scene tree. You can read about it here -

2 Likes

Also how I can get Team 2 path or Team 1 path (see picture)

If your code is in the root node, you can made them scene unique names and call GetNode(“%Team1”) (that’s c#, I think gdscript’s notation is slightly different?)