1234567891011121314151617181920212223 |
- using System;
- using UnityEngine;
- using UnityEngine.Playables;
- using UnityEngine.Timeline;
- [Serializable]
- public class CurveControlClip : PlayableAsset, ITimelineClipAsset
- {
- public CurveControlBehaviour template = new CurveControlBehaviour();
- public TimelineClip clipPassthrough = null;
- public ClipCaps clipCaps
- {
- get { return ClipCaps.Blending; }
- }
- public override Playable CreatePlayable(PlayableGraph graph, GameObject owner)
- {
- template.Clip = clipPassthrough;
- var playable = ScriptPlayable<CurveControlBehaviour>.Create(graph, template);
- return playable;
- }
- }
|