Search Unity

Timeline pause - weird animation behaviour

Discussion in 'Timeline' started by O_R_U, May 14, 2020.

  1. O_R_U

    O_R_U

    Joined:
    Dec 11, 2019
    Posts:
    4
    Hi,

    First time posting here :)
    I'm using Timeline to create a cutscene. This cutscene combines dialogues triggered through signals and animations.
    Once a dialogue starts, i immediately pause the playable director, and use a script to trigger play again once the dialogue is finished.

    The weird thing is, once pause is triggered, animations further down the timeline start triggering.

    I've tried playing around with just about every input possible, but I'm stumped...

    Thanks in advance!
     
  2. seant_unity

    seant_unity

    Unity Technologies

    Joined:
    Aug 25, 2015
    Posts:
    1,516
  3. O_R_U

    O_R_U

    Joined:
    Dec 11, 2019
    Posts:
    4
    Thanks @seant_unity!
    What's the default timeline speed? Tried writing a function to make the timeline "play" again, but couldn't make it go.
    Tried this: playableDirector.playableGraph.GetRootPlayable(0).SetSpeed(X);

    With X as 1 or 20 or 500 and no result
     
  4. seant_unity

    seant_unity

    Unity Technologies

    Joined:
    Aug 25, 2015
    Posts:
    1,516
    1 is the default speed. The speed needs to be set after 'Play', so that the instance of the timeline (playableGraph) is ready. Playable.playableGraph.IsValid() is how to check if the graph is instantiated.
     
  5. O_R_U

    O_R_U

    Joined:
    Dec 11, 2019
    Posts:
    4
    Thank you! Works great now