New answers tagged position
I think some trigonometry classes would help you. Meaning of variables position.x is the x coordinate, and position.z is the y (if 2D game) or z (3D game) coordinate. Yaw is the rotation (in radians I think). So when user presses A do yaw--; and when user presses S do yaw++;. Distance is how far to move (sort of like speed). NOTE: This is written in Java. ...
One way to do it is to keep track of the Front and Up normalized vectors and transform the front vector whenever your character turns, and calculate the Right vector using cross product ( I am assuming Up vector won't rotate). Or you can keep track of the three vectors and rotate them. Once you rotate them you update the position by adding the offset in the ...
In the approach you want to follow that is disabling other camera use GameObject.SetActive.
Top 50 recent answers are included