playMaker

Author Topic: Switch camera with raycast  (Read 2286 times)

insiderrr

  • Playmaker Newbie
  • *
  • Posts: 10
Switch camera with raycast
« on: March 30, 2015, 09:58:06 AM »
I have this challenge to use the camera raycast to switch from camera position.

I use this in combination with the 'cut to camera ' action, but when the ray activates it, there is no change in teh scene, the module of the cut to camera shows green, but i still get the same view.

Any idea how to make this work ?

The idea behind this construction is that i can explore the scene by looking at specific objects without walking to that point.

TheBadFeeling

  • Junior Playmaker
  • **
  • Posts: 67
Re: Switch camera with raycast
« Reply #1 on: March 30, 2015, 04:21:21 PM »
I've had my share of trouble with similar Cut To Camera functionality, and I know many others had too. Unity just wouldn't always let me switch, even though I set the new camera to Maincamera. Sometimes, but not always.   ???

Thus, I ended up both deactivating the "normal" camera and activating the new one before switching. And the other way around cutting back. Bumpy, but functioning.

/Bad
The Force is with you, young Playmaker – but you are not a C# senpai yet.

insiderrr

  • Playmaker Newbie
  • *
  • Posts: 10
Re: Switch camera with raycast
« Reply #2 on: March 31, 2015, 05:12:43 AM »
Thanx for your replay,

I was trying teh exact same setup as you showed me, but here is the next challange. I use an oculus rift setup, this rig is using 3 cameras. For the cut to camera you can display 1 camera, wondering whats the best sulution is for this.

and another challenge i had, when i disable the camera i can do 1 switch, after that the camera keeps activated and i can not de-activated it again. i thougt there was also a de-activation camera action, but it seems not.

if my explanation is not clear, i will try to add more details. i think it must be possible, so close...