Skip to content

Commit

Permalink
Fix phaserjs#7018. Animation playback prioritises animation config ob…
Browse files Browse the repository at this point in the history
…ject.
  • Loading branch information
zekeatchan committed Feb 6, 2025
1 parent f4cf661 commit a8f921b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/animations/Animation.js
Original file line number Diff line number Diff line change
Expand Up @@ -362,7 +362,7 @@ var Animation = new Class({
// When is the first update due?
state.accumulator = 0;

state.nextTick = (state.currentFrame.duration) ? state.currentFrame.duration : state.msPerFrame;
state.nextTick = state.msPerFrame || state.currentFrame.duration;
},

/**
Expand Down Expand Up @@ -515,7 +515,7 @@ var Animation = new Class({
{
state.accumulator -= state.nextTick;

state.nextTick = (state.currentFrame.duration) ? state.currentFrame.duration : state.msPerFrame;
state.nextTick = state.msPerFrame || state.currentFrame.duration;
},

/**
Expand Down

0 comments on commit a8f921b

Please sign in to comment.