Search Unity

Impossible to Ease In

Discussion in 'Cinemachine' started by Misscelan, Feb 4, 2019.

  1. Misscelan

    Misscelan

    Joined:
    Mar 8, 2013
    Posts:
    176
    Is there any reason why this cinematic is not blending in from Gameplay?


    The cam (CM vcam5) has a Ease In of 2secs and I the Brain is also set up to Ease in(I know this one should not matter but just in case).

    Thanks
     
  2. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    7,711
    You're right, the brain setting makes no difference here.
    What is the current active vcam in your scene, if you disable that timeline track?
     
  3. Misscelan

    Misscelan

    Joined:
    Mar 8, 2013
    Posts:
    176
    If I disable the timeline track there are no vcams activated.



    Also, the Brain is comming from another scene so before playing the cinematic I assign it through a script and yield one frame just in case it needs to set up something (no difference if I don't wait).

    Code (CSharp):
    1. CinemachineBrain l_brain = COMMON_Camera.m_instance.GetComponent<CinemachineBrain>();
    2. TimelineAsset l_timelineAsset = (TimelineAsset)m_cutscene.playableAsset;
    3. TrackAsset l_track = (TrackAsset)l_timelineAsset.GetOutputTrack(0);
    4. m_cutscene.SetGenericBinding(l_track, l_brain);
    5.  
    6. yield return null;
    7.  
    8. m_cutscene.Play();
    9.  
     
  4. Misscelan

    Misscelan

    Joined:
    Mar 8, 2013
    Posts:
    176
    Got it sorted. I was activating/deactivating the brain on each cinematic (because of a previous bug). If I leave it on, it works.
     
    Gregoryl likes this.