I am a visual designer and I am trying to find my way into a bit of the unity engine. I am trying to put the things that I create in cinema 4D into a virtual environment and walk though it. But the camera script that is standard in Unity (the First Person Controller) is unsuitable for casual walk throughs. I searched the web for smooth camera in Unity and found an entry at this link to newarteest.com/unity And what I found there was exactky what I would expect of a camera to act like (turning with the arrow keys and only looking with click-and-drag movement.
How could I achieve this? I looked in the input manager but could find no reference to heading and pitch axes there...
In the Input Manager you can define an input axis (call it "Turn" or "Horizontal") and map the A and D keys to the axis' negative and positive triggers. When A is down the axis will be -1, when D is down the axis will be 1, otherwise it will be 0. You can use those values to rotate your player object in an Update function.
Put this in a script attached to the game object that holds your Character Controller component:
var turnSpeed : float = 2.0;
function Update() {
transform.Rotate(Vector3(0, Input.GetAxisRaw("Horizontal") * Time.deltaTime * turnSpeed, 0));
}