// Animancer // Copyright 2020 Kybernetik // using UnityEngine; namespace Animancer { /// /// Interface for components that manage an . /// /// /// Despite the name, this interface is not necessarily limited to only components. /// /// This interface allows Animancer Lite to reference an inside the pre-compiled /// DLL while allowing that component to remain outside as a regular script. Otherwise everything would need to be /// in the DLL which would cause Unity to lose all the script references when upgrading from Animancer Lite to Pro. /// public interface IAnimancerComponent { /************************************************************************************************************************/ #pragma warning disable IDE1006 // Naming Styles. /************************************************************************************************************************/ /// Indicates whether this component will be updated. bool enabled { get; } /// The this component is attached to. GameObject gameObject { get; } /************************************************************************************************************************/ #pragma warning restore IDE1006 // Naming Styles. /************************************************************************************************************************/ /// The component which this script controls. Animator Animator { get; set; } /// The internal system which manages the playing animations. AnimancerPlayable Playable { get; } /// Indicates whether the has been initialised (is not null). bool IsPlayableInitialised { get; } /// Determines whether the object will be reset to its original values when disabled. bool ResetOnDisable { get; } /// /// Determines when animations are updated and which time source is used. This property is mainly a wrapper /// around the . /// AnimatorUpdateMode UpdateMode { get; set; } /************************************************************************************************************************/ /// /// Returns the dictionary key to use for the `clip`. /// object GetKey(AnimationClip clip); /************************************************************************************************************************/ #if UNITY_EDITOR /************************************************************************************************************************/ /// [Editor-Only] The name of the serialized backing field for the property. string AnimatorFieldName { get; } /// [Editor-Only] The what was first used when this script initialised. AnimatorUpdateMode? InitialUpdateMode { get; } /************************************************************************************************************************/ #endif /************************************************************************************************************************/ } }