Class AbstractFiniteState

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

public abstract class AbstractFiniteState extends Object
Base class for a finite state in our finite state machine.
  • Constructor Details

    • AbstractFiniteState

      public AbstractFiniteState()
  • Method Details

    • resetClips

      public void resetClips(AnimationManager manager)
      Reset the clip instances held by this state's blend tree (or other leaf nodes in our blend tree) to a start time using the current global time from the given manager.
      Parameters:
      manager - our manager.
    • resetClips

      public void resetClips(AnimationManager manager, double globalStartTime)
      Reset the clip instances held by this state's blend tree (or other leaf nodes in our blend tree) to given start time.
      Parameters:
      manager - our manager.
      globalStartTime - the new start time to use.
    • update

      public abstract void update(double globalTime, AnimationLayer layer)
      Update this state using the current global time.
      Parameters:
      globalTime - the current global time.
      layer - the layer this state belongs to.
    • postUpdate

      public abstract void postUpdate(AnimationLayer layer)
      Post update. If the state has no more clips and no end transition, this will clear this state from the layer.
      Parameters:
      layer - the layer this state belongs to.
    • getCurrentSourceData

      public abstract Map<String,? extends Object> getCurrentSourceData(AnimationManager manager)
      Parameters:
      manager - animation manager
      Returns:
      the current map of source channel data for this layer.
    • setLastStateOwner

      public void setLastStateOwner(StateOwner owner)
      Parameters:
      owner - the last holder of this state. Used when we are transitioning and need to ask someone to swap us with another state. Generally only called by the AnimationLayer or by transitioning states that reference other states.
    • getLastStateOwner

      public StateOwner getLastStateOwner()
      Returns:
      the last holder of this state.
      See Also:
    • getGlobalStartTime

      protected double getGlobalStartTime()
      Returns:
      the global time this state was last set to use as a start reference. Meant for subclass use only.