godot get global position 3d

To get the global position of a 3D node in GDScript in the Godot game engine, you can use the global_transform.origin property. Here's an example:

var globalPosition = your_node.global_transform.origin

This will give you the global position of the node in 3D space. Make sure to replace your_node with the actual node you want to get the position of.