// Animancer // https://kybernetik.com.au/animancer // Copyright 2018-2024 Kybernetik // namespace Animancer { /// An object which can create an and set its details. /// /// Transitions are generally used as arguments for . /// /// Documentation: /// /// Transitions /// /// https://kybernetik.com.au/animancer/api/Animancer/ITransition public interface ITransition : IHasKey, IPolymorphic { /************************************************************************************************************************/ /// The amount of time this transition should take (in seconds). float FadeDuration { get; } /// /// The which should be used when this transition is passed into /// . /// FadeMode FadeMode { get; } /// Creates and returns a new defuned by this transition. /// /// The first time a transition is used on an object, this method creates a state /// which is registered in the internal dictionary using the /// so that it can be reused later on. /// /// Methods like will also call , /// so if you call this method manually you may want to call that method as well. /// Or you can just use . /// AnimancerState CreateState(); /// Applies the details of this transition to the `state`. /// This method is called by every . void Apply(AnimancerState state); /************************************************************************************************************************/ } /// An which creates a specific type of . /// /// Documentation: /// /// Transitions /// /// https://kybernetik.com.au/animancer/api/Animancer/ITransition_1 public interface ITransition : ITransition where TState : AnimancerState { /************************************************************************************************************************/ /// /// The state that was created by this object. Specifically, this is the state that was most recently /// passed into (usually by ). /// TState State { get; } /************************************************************************************************************************/ /// Creates and returns a new . new TState CreateState(); /************************************************************************************************************************/ } }