ActivationPlayableAsset.cs 838 B

1234567891011121314151617181920212223242526272829
  1. #if UNITY_EDITOR
  2. using System.ComponentModel;
  3. #endif
  4. using UnityEngine.Playables;
  5. namespace UnityEngine.Timeline
  6. {
  7. /// <summary>
  8. /// Playable Asset class for Activation Tracks
  9. /// </summary>
  10. #if UNITY_EDITOR
  11. [DisplayName("Activation Clip")]
  12. #endif
  13. class ActivationPlayableAsset : PlayableAsset, ITimelineClipAsset
  14. {
  15. /// <summary>
  16. /// Returns a description of the features supported by activation clips
  17. /// </summary>
  18. public ClipCaps clipCaps { get { return ClipCaps.None; } }
  19. /// <summary>
  20. /// Overrides PlayableAsset.CreatePlayable() to inject needed Playables for an activation asset
  21. /// </summary>
  22. public override Playable CreatePlayable(PlayableGraph graph, GameObject go)
  23. {
  24. return Playable.Create(graph);
  25. }
  26. }
  27. }