SignalAsset.cs 634 B

12345678910111213141516171819202122
  1. using System;
  2. using UnityEngine;
  3. namespace UnityEngine.Timeline
  4. {
  5. /// <summary>
  6. /// An asset representing an emitted signal. A SignalAsset connects a SignalEmitter with a SignalReceiver.
  7. /// </summary>
  8. /// <seealso cref="UnityEngine.Timeline.SignalEmitter"/>
  9. /// <seealso cref="UnityEngine.Timeline.SignalReceiver"/>
  10. [AssetFileNameExtension("signal")]
  11. public class SignalAsset : ScriptableObject
  12. {
  13. internal static event Action<SignalAsset> OnEnableCallback;
  14. void OnEnable()
  15. {
  16. if (OnEnableCallback != null)
  17. OnEnableCallback(this);
  18. }
  19. }
  20. }