#How to align 3D movement with camera?
2 messages · Page 1 of 1 (latest)
In 3D, you can use your camera's 'global basis' property to figure out where
it's currently pointing at. Say you want to move an object towards the camera's
right, you can use 'camera.GlobalBasis.X' (or 'camera.global_basis.x', in
GDScript).
Most movement in 3D are typically ground-based, so you'll probably be mostly
using the X and Z axes.
Relevant Docs:
(Basis Info)
https://docs.godotengine.org/en/stable/classes/class_basis.html
(General 3D Transform Info)
https://docs.godotengine.org/en/stable/tutorials/3d/using_transforms.html
A 3×3 matrix for representing 3D rotation and scale. Description: A 3×3 matrix used for representing 3D rotation and scale. Usually used as an orthogonal basis for a Transform3D. Contains 3 vector ...
Introduction: If you have never made 3D games before, working with rotations in three dimensions can be confusing at first. Coming from 2D, the natural way of thinking is along the lines of"Oh, it'...