Skip to content

Commit

Permalink
[ts] Port of commit c2fe1a3, Added TrackEntry IsNextReady. See #2547.
Browse files Browse the repository at this point in the history
  • Loading branch information
davidetan committed Jun 11, 2024
1 parent b4d6179 commit 2ac0307
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions spine-ts/spine-core/src/AnimationState.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1032,6 +1032,12 @@ export class TrackEntry {
wasApplied () {
return this.nextTrackLast != -1;
}

/** Returns true if there is a {@link #getNext()} track entry and it will become the current track entry during the next
* {@link AnimationState#update(float)}. */
isNextReady () {
return this.next != null && this.nextTrackLast - this.next.delay >= 0;
}
}

export class EventQueue {
Expand Down

0 comments on commit 2ac0307

Please sign in to comment.