I have three cameras in my scene. One follows the body of the tank, one follows the turret of the tank (rotation), and eventually, i want one that is a "zoomed-in" view. However, when I go to drag my cameras into the "camera1""camera2" variable slots in the inspector, I just simply cant. No errors or anything, it's just physically impossible to drag it onto the slot.
Here's a screenshot. You can see my code, and variables on the right, and my cameras on the left.

Here's the code I'm using, and I've seen it a hundred times.
var camera1 : Camera;
var camera2 : Camera;
function Start () {
camera1.enabled = true;
camera2.enabled = false;
}
function Update () {
if (Input.GetKeyDown ("2")){
camera1.enabled = false;
camera2.enabled = true;
}
if (Input.GetKeyDown ("1")){
camera1.enabled = true;
camera2.enabled = false;
}
}
have you put the script on something? I can't attach cameras to the script until I've actually put it on something.
– cidmodderIf you can, post an answer (not a comment) stating the solution and mark it as accepted. It takes it off the "unanswered" list.
– TheDemiurgeNot quite at the bottom, they need to be included in the main namespace and part of the class (see the comments in the snippet above). Here;s the full file I'm using: [RigidbodyFPControllerCardboard.cs][1] [1]: http://baroquedub.co.uk/private/temp/RigidbodyFPControllerCardboard.cs
– baroquedub