Skip to content

Commit 70bedbd

Browse files
committed
Check if animation exists
1 parent b7ae029 commit 70bedbd

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/gameobjects/components/Animation.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -817,7 +817,7 @@ var Animation = new Class({
817817
*/
818818
update: function (timestamp, delta)
819819
{
820-
if (this.isPlaying || !this.currentAnim.paused)
820+
if (this.currentAnim && (this.isPlaying || !this.currentAnim.paused))
821821
{
822822
this.accumulator += delta * this._timeScale;
823823

0 commit comments

Comments
 (0)