Direction of an object relative to player facing direction
i want to make an object move on its own to the direction my camera is facing. i have managed to make the object move but i cant figure out how to fix the direction , any ideas ?
2 Replies
so with this code inside my update the object starts to move in the Z
and i basically want it to move to the direction i am facing with my camera
use
yourCamera.transform.TranslateDirection(..)
set the y of that result to 0 so it doesn't move up