Forum rules - please read before posting.

Custom Camera script issue

Hey Chris,
  Why is it when I add the 'Camera' script to my custom camera, during runtime the game still shows the render from the Main Camera instead.  I unchecked the 'camera' on my custom one and the Main camera is tagged main camera.  The custom in not tagged at all, and everything is on the ignore raycast layer.  when I remove the maincamera from scene my custom works fine

Comments

  • That's how AC works - the MainCamera will snap itself to whichever camera you tell it - whether it's the "Default camera" you assign in the Scene Manager, or a new one in-game by using the Camera: Switch Action.  This allows you to move in between cameras smoothly over time - the non-MainCameras are used for placement only, and aren't actually rendering.

    Once you add the "Camera" script to your custom camera, it's then available to be used in your game, either by using the "Camera: Switch" Action, or by setting it as the default camera in the Scene Manager.
  • Yes I got it to work but in a slightly different way.  What you said is what I did before, except that my custom camera couldn't allow me to use its custom script unless I made it the MainCamera tag.  That caused it to act weird since I needed the Adventure Creator's mainCamera prefab.  When I made the Camera: Switch, it worked but wouldn't allow me to add my custom camera in the  'camer' field to switch back to. 

     

    therefore, I added an Object: Remove action and just deleted the specific zoom in camera for the spot and then once it's gone from scene it automatically jumps back to my regular custom camera

    :)>-

     

    Thanks

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.