Class AbstractTransitionState

java.lang.Object
com.ardor3d.extension.animation.skeletal.state.AbstractFiniteState
com.ardor3d.extension.animation.skeletal.state.AbstractTransitionState
Direct Known Subclasses:
AbstractTwoStateLerpTransition, IgnoreTransitionState, ImmediateTransitionState

public abstract class AbstractTransitionState extends AbstractFiniteState
Base class for transition states - states responsible for moving between other finite states.
  • Constructor Details

    • AbstractTransitionState

      protected AbstractTransitionState(String targetState)
      Construct a new transition state.
      Parameters:
      targetState - the name of the steady state we want the Animation Layer to be in at the end of the transition.
  • Method Details

    • getTargetState

      public String getTargetState()
      Returns:
      the name of the steady state we want the Animation Layer to be in at the end of the transition.
    • setStartWindow

      public void setStartWindow(double startWindow)
      Parameters:
      startWindow - our new start window value. If greater than 0, this transition is only valid if the current time is greater than or equal to startWindow. Note that animations are separate from states, so time scaling an animation will not affect transition windows directly and must be factored into the start/end values.
    • getStartWindow

      public double getStartWindow()
      Returns:
      our start window value.
      See Also:
    • setEndWindow

      public void setEndWindow(double endWindow)
      Parameters:
      endWindow - our new end window value. If greater than 0, this transition is only valid if the current time is less than or equal to endWindow. Note that animations are separate from states, so time scaling an animation will not affect transition windows directly and must be factored into the start/end values.
    • getEndWindow

      public double getEndWindow()
      Returns:
      our end window value.
      See Also:
    • doTransition

      public final AbstractFiniteState doTransition(AbstractFiniteState callingState, AnimationLayer layer)
      Request that this state perform a transition to another.
      Parameters:
      callingState - the state calling for this transition.
      layer - the layer our state belongs to.
      Returns:
      the new state to transition to. May be null if the transition was not possible or was ignored for some reason.