Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Offsync at first play

Discussion in 'Timeline' started by wtetotew, Dec 7, 2020.

  1. wtetotew

    wtetotew

    Joined:
    Apr 12, 2020
    Posts:
    61
    Hi!


    If I open and play my scene for the first time, I will get an offset about 4 second of my audio track.
    All other element are in sync( I'm using a midi extension).
    If I stop and push play button again, now everything is in sync. Do you have any Idea why?

    Regards.
     
  2. seant_unity

    seant_unity

    Unity Technologies

    Joined:
    Aug 25, 2015
    Posts:
    1,516
    There's a few things that may help
    • Set the playable director Update mode to DSP graph, if it's not. This plays timeline off the audio clock, like the audio clips are. This might cause the entire timeline to jump forward though.
    • Turn off play on awake on the playable director, and start playing the timeline from a coroutine or start method instead that gives the scene time to load or initialize before the timeline starts playing.
    Also, some bugs were fixed related to this in 2019.3 if you are using an older version upgrading to 2019.4 (if possible) may help.
     
  3. wtetotew

    wtetotew

    Joined:
    Apr 12, 2020
    Posts:
    61
    Starting the Timeline from the Start method fixed the issue, thank you very much!