Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Give POV virtual camera a specific starting orientation

Discussion in 'Cinemachine' started by LilyMcCheddar, Mar 15, 2018.

  1. LilyMcCheddar

    LilyMcCheddar

    Joined:
    Feb 4, 2017
    Posts:
    10
    Hi !
    I have been trying to get a specific behaviour on a first person camera for months now but couldn't make it work. I am trying to implement it with cinemachine.

    I want my player camera to blend into a "hard look" camera to get a transition, and then let the player take back the controls by switching again to a "clamped" version of a POV camera.

    cinemachineblend.PNG

    I have all my cameras working with more or less the behaviour I want, but when I switch from my HardLook camera to my POV camera, it "snaps" into a position instead of starting out where I want. Here's a GIF that might help understand what I mean : http://gph.is/2ItDhru

    Is there any way I could set a default start position for the POV camera and avoid that "snap" ?

    Or is cinemachine the wrong approach here ? I already have a system that works with Lerp methods to switch position, but I am really missing this "clamped and heavy" camera in close interactions.
    Any help would be truly appreciated !
     
  2. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    7,658
    The orientation of the POV is controlled by the "Value" field in the axes. Set those to the value you want (usually 0, if you want it to look straight ahead - that's the default).

    However, the POV does update its orientation to follow the mouse while it's enabled, even when it's not Live. Probably that's why it's not starting at 0. To suppress that behaviour, disable the POV vcam gameObject. Timeline will force-enable it while its clip is active.
     
  3. LilyMcCheddar

    LilyMcCheddar

    Joined:
    Feb 4, 2017
    Posts:
    10
    Thank you @Gregoryl ! I had no idea the camera would record input when it's not live.