Camera Follow+orbit = Jitter

I have a camera with both the mouse follow and the mouse orbit script attached, and the ball set as the target. I’m getting intermittent but serious jittering.

Here’s a web player http://homepages.wmich.edu/~abbott/unity/Ball/BallCameraProblem.html

When I watch it in the editor window the camera is just jumping up and back. If I turn off one or the other script the problem goes away.

The ball is controlled via the Rolling Ball Script from the Unity tutorial

Would anyone happen to know the conflict?

thanks

Kevin

by mouse follow do you mean mouse look or smooth follow? either way it sounds like you have 2 scripts setting the camera position/rotation. that won’t work. you need to either combine the scripts so that they take the other’s result into account and then slerp/lerp the final position/rotation or if it’s the smooth follow script, just get rid of that one and parent the camera to your object.