[libgdx] AnimationState javadoc.

This commit is contained in:
NathanSweet 2018-10-17 11:23:44 +02:00
parent 7183e3b0bd
commit d0d22bb344

View File

@ -534,9 +534,10 @@ public class AnimationState {
/** Adds an animation to be played after the current or last queued animation for a track. If the track is empty, it is
* equivalent to calling {@link #setAnimation(int, Animation, boolean)}.
* @param delay Seconds to begin this animation after the start of the previous animation. If <= 0, uses the duration of the
* previous track entry minus any mix duration plus the specified <code>delay</code>. If the previous entry is
* looping, its next loop completion is used instead of the duration.
* @param delay If > 0, sets {@link TrackEntry#getDelay()}. If <= 0, the delay set is the duration of the previous track entry
* minus any mix duration plus the specified <code>delay</code> (ie the mix ends at (<code>delay</code> = 0) or
* before (<code>delay</code> < 0) the previous track entry duration). If the previous entry is looping, its next
* loop completion is used instead of its duration.
* @return A track entry to allow further customization of animation playback. References to the track entry must not be kept
* after the {@link AnimationStateListener#dispose(TrackEntry)} event occurs. */
public TrackEntry addAnimation (int trackIndex, Animation animation, boolean loop, float delay) {
@ -598,9 +599,10 @@ public class AnimationState {
* {@link #setEmptyAnimation(int, float)}.
* <p>
* See {@link #setEmptyAnimation(int, float)}.
* @param delay Seconds to begin this animation after the start of the previous animation. If <= 0, uses the duration of the
* previous track entry minus any mix duration plus the specified <code>delay</code>. If the previous entry is
* looping, its next loop completion is used instead of the duration.
* @param delay If > 0, sets {@link TrackEntry#getDelay()}. If <= 0, the delay set is the duration of the previous track entry
* minus any mix duration plus the specified <code>delay</code> (ie the mix ends at (<code>delay</code> = 0) or
* before (<code>delay</code> < 0) the previous track entry duration). If the previous entry is looping, its next
* loop completion is used instead of its duration.
* @return A track entry to allow further customization of animation playback. References to the track entry must not be kept
* after the {@link AnimationStateListener#dispose(TrackEntry)} event occurs. */
public TrackEntry addEmptyAnimation (int trackIndex, float mixDuration, float delay) {
@ -859,9 +861,10 @@ public class AnimationState {
this.loop = loop;
}
/** Seconds to postpone playing the animation. When a track entry is the current track entry, <code>delay</code> postpones
* incrementing the {@link #getTrackTime()}. When a track entry is queued, <code>delay</code> is the time from the start of
* the previous animation to when the track entry will become the current track entry. */
/** Seconds to postpone playing the animation. When this track entry is the current track entry, <code>delay</code>
* postpones incrementing the {@link #getTrackTime()}. When this track entry is queued, <code>delay</code> is the time from
* the start of the previous animation to when this track entry will become the current track entry (ie when the previous
* track entry {@link TrackEntry#getTrackTime()} >= this track entry's <code>delay</code>). */
public float getDelay () {
return delay;
}