Search Unity

blending Freelook to vcam, then back to Freelook

Discussion in 'Cinemachine' started by sandBucket2, Sep 5, 2019.

  1. sandBucket2

    sandBucket2

    Joined:
    Mar 26, 2016
    Posts:
    23
    Hey guys,

    I have a third person camera setup as freelook, and I'm blending from freelook to a vcam.

    I've noticed that when I blend from freelook to vcam, and back to freelook, it blends back to the freelook's last known location. Depending on the situation, this can lead to an awkward blend when the freelook's last player controlled transform is somewhere close to the ground.

    Is there a way to cleanly change the transform of the freelook cam while the vcam is being displayed? I feel that if I change the freelook transform manually rather than the player doing it, the whole third person cam will be thrown off.

    Any help is appreciated and thanks!
     
  2. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    2,844
    Have you tried checking this in the FreeLook?

    upload_2019-9-5_14-56-58.png
     
  3. sandBucket2

    sandBucket2

    Joined:
    Mar 26, 2016
    Posts:
    23
    that has no effect unfortunately :\ I've checked that box on both cams in all different combinations. I'm using timeline for the transitions, maybe that has something to do with it, I'm not sure.

    I want to be able to make the freelook cam reset its transform to face north when the vcam blends back into the freelook cam.
     
    Last edited: Sep 6, 2019
  4. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    2,844
    InheritPosition will make the FreeLook choose a point on its orbit that's closest to the outgoing vcams'm position. I thought that's what you wanted. If instead you want it to take some default setting whenever it gets activated, you could write a code snippet that you hook into its OnCameraLive event (just below the arrow, in the image above), that resets the FreeLook's X and Y axis Values to some known thing (e.g. 0). In that case, you should uncheck InheritPosition.