Hi, I’ve been trying to make my own character controller using rigidbodies. This is going quite well so far, but I keep bumping into one problem.
I use the ImprovedMouseOrbit script for my camera. And this all works perfectly. The only problem is, I want my character always facing where you point your camera (third person). I’m now using:
transform.rotation.y =
maincam.transform.rotation.y;
To make the character face correctly, but when you rotate to around Y 180 the character doesn’t rotate with the camera anymore. If you rotate even more, it well do it again but the wrong way.
I thought this basic approach was quite solid, what am I overseeing?
I’ve tried this with FPSController prefab and my own character controller. So I’m pretty sure it doesn’t have to do with the other scripts.