Search Unity

Creating And Saving Timeline Instance

Discussion in 'Timeline' started by ajsmith22, Jul 19, 2017.

  1. ajsmith22

    ajsmith22

    Joined:
    Jun 20, 2015
    Posts:
    9
    In the Project view, it's possible to Right Click > Create > Timeline, which adds a new Timeline to the project. In code, I can create an Instance of a TimelineAsset and assign it to the PlayableDirector, but something I can't do is save said TimelineAsset, as you would if you created a Timeline in the Scene View. Is there a way to save one of these TimelineAssets as you would a prefab?
     
  2. ajsmith22

    ajsmith22

    Joined:
    Jun 20, 2015
    Posts:
    9
    Looks like you can do it with the AssetDatabase.CreateAsset method.
     
    julienb and seant_unity like this.