summaryrefslogtreecommitdiff
path: root/Library/PackageCache/com.unity.timeline@1.2.13/Runtime/Events/MarkerTrack.cs
blob: f64b483e418669ca23a83301a48c217e1861fefb (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
using System;
using System.Collections.Generic;
using UnityEngine.Playables;

namespace UnityEngine.Timeline
{
    /// <inheritdoc />
    /// <summary>
    /// Use this track to add Markers bound to a GameObject.
    /// </summary>
    [Serializable]
    [TrackBindingType(typeof(GameObject))]
    [HideInMenu]
    [ExcludeFromPreset]
    public class MarkerTrack : TrackAsset
    {
        /// <inheritdoc/>
        public override IEnumerable<PlayableBinding> outputs
        {
            get
            {
                return this == timelineAsset.markerTrack ?
                    new List<PlayableBinding> {ScriptPlayableBinding.Create(name, null, typeof(GameObject))} :
                    base.outputs;
            }
        }
    }
}