FYI, you need to indent code or wrap it in backticks
like this for formatting, or use the "Code Sample" button in the editor when you're writing your post.
3D nodes don't have a
position property. All 3D nodes inherit from Spatial:
A Spatial node has a
transform (and a
global_transform). Transforms contain the position, rotation, and scale information of the body in the form of a matrix. You can access the individual components by
transform.origin - the coordinates in 3D space, and
transform.basis - which contains the orientation.
More about transforms here:
The other problem I see in your code is that you can't use the mouse position in 3D. The mouse doesn't exist in 3D. It is "stuck" to the 2D plane of your camera. It doesn't have any "depth" into the screen, so you can't get its "position" relative to a 3D object.
To click-and-move in 3D, you need to project the mouse position "into" the world and see what it contacted. Collision objects can do this automatically, so if the ground is a StaticBody, for example, you can connect its
input_event signal and it'll detect when and where it's been clicked on. You can use this coordinate to determine how to move your character.