Switching Cameras

How do you jump between camera views? Is it a render call?

nope

function SwitchCamera()
{
    GameObject.Find("Cam1").camera.enabled = !GameObject.Find("Cam1").camera.enabled;
    GameObject.Find("Cam2").camera.enabled = !GameObject.Find("Cam1").camera.enabled;
}

Wow. alot easier than I thought it would be. thank you!

how do I make it so that when i right click it changes cameras?

if (Input.GetMouseButtonDown(1)) {
  SwitchCamera();        //as posted by _Daniel_
}

thanks haha but now ive moved from a fps to island survival game xD

Aww, but that still may be useful in the island survival game. Who knows! :slight_smile:

Well, here, we don’t jump between camera… We jump between camera context. We only have one camera, and we tell it where to go.