I am making a third person game and I have an issue with the camera. The way the camera works is by following an empty game object that is a child of the player. I put the empty game object to the right of the player to make room for the cross hair and so that the cross hair can be in the center of the screen. The problem is that when the player is facing the camera they flip to the left of the cross hair.
Easiest way is to not have it as a child. Rather write a follow script. Position the camera in the position you want then start the game.
public class CameraFollow : MonoBehaviour {
Vector3 offset;
Transform player;
void Start () {
offset = transform.postion - player.position;
}
void LateUpdate () {
transform.position = Vector3.lerp (transform.position, player.position + offset, 1f);
}
}