- Home /
Change camera angle for 3rd person controller
Hey,
I've tried a lot of things but the angle of the camera camera doesn't seem to move.
I want the camera to look down at the character like this:
In the updateSmoothedMovementDirection() function I tried applying the rotation coordinates to camera using:
Camera.main.transform.localPosition = Vector3(-1.466671,7.634815,-34.35412);
Camera.main.transform.localRotation = Quaternion.Euler(45f, 0f, 0f);
The position changes fine. However the rotation does not.
Note: i'm working with the standard unity 3rd person controller.
is there anything in doing wrong here?
Answer by frogsbo · Mar 16, 2014 at 02:58 PM
you can use transform.lookat to point the camera always at or near player, then just rotate camera. you can also try a lookrotation on the camera in quaternions is the same but probably more pro.