- Home /
Want my camera to only move on a Horizontal Axis
I'm making a zelda type game and I want the camera to be locked on the character and follow at all times. But most of the scripts i've use have the camera pitching up and down as well as shifting left to right when I move. i just want the camera to move on a horizontal axis following the character. Any tips?
Comment
Answer by Griffo · Jul 13, 2013 at 07:48 AM
Try something like -
var lookPos = player.position - transform.position;
lookPos.y = 0;