We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 2ce2f30 + 4842a1f commit 9cb1022Copy full SHA for 9cb1022
cocos2d/sprite_nodes/CCAnimationCache.js
@@ -175,7 +175,7 @@ cc.AnimationCache = cc.Class.extend(/** @lends cc.AnimationCache# */{
175
var animationDict = animations[key];
176
177
var loopsTemp = parseInt(animationDict["loops"]);
178
- var loops = (loopsTemp == null) ? 1 : loopsTemp;
+ var loops = (!isNaN(loopsTemp)) ? 1 : loopsTemp;
179
var restoreOriginalFrame = (animationDict["restoreOriginalFrame"] && animationDict["restoreOriginalFrame"] == true) ? true : false;
180
var frameArray = animationDict["frames"];
181
0 commit comments