Discord
Login
Community
DARK THEME

Angled movement

How do I make the camera move to where it's facing

you can use trigonomety to figure out the coordinates of the spot 1 thing in front of it

x = cos(camera.rotation.y) y = sin(camera.rotation.x) z = sin(camera.rotation.y)

camera.position.x += x camera.position.y += y camera.position.z += z

I haven't actually tried it out so it might not work

Post a reply

Progress

Status

Preview
Cancel
Post
Validate your e-mail address to participate in the community