@@ -48,8 +48,8 @@ this.createjs = this.createjs||{};
48
48
*
49
49
* <h4>Example</h4>
50
50
*
51
- * var instance = new createjs.Sprite(spriteSheet);
52
- * instance.gotoAndStop("frameName");
51
+ * var instance = new createjs.Sprite(spriteSheet);
52
+ * instance.gotoAndStop("frameName");
53
53
*
54
54
* Until {{#crossLink "Sprite/gotoAndStop"}}{{/crossLink}} or {{#crossLink "Sprite/gotoAndPlay"}}{{/crossLink}} is called,
55
55
* only the first defined frame defined in the sprite sheet will be displayed.
@@ -229,7 +229,7 @@ this.createjs = this.createjs||{};
229
229
return true ;
230
230
} ;
231
231
232
- //Note, the doc sections below document using the specified APIs (from DisplayObject) from
232
+ //Note, the doc sections below document using the specified APIs (from DisplayObject) from
233
233
//Bitmap. This is why they have no method implementations.
234
234
235
235
/**
@@ -336,7 +336,7 @@ this.createjs = this.createjs||{};
336
336
* @return {String } a string representation of the instance.
337
337
**/
338
338
p . toString = function ( ) {
339
- return "[Sprite (name=" + this . name + ")]" ;
339
+ return "[Sprite (name=" + this . name + ")]" ;
340
340
} ;
341
341
342
342
// private methods:
@@ -464,7 +464,10 @@ this.createjs = this.createjs||{};
464
464
this . _animation = data ;
465
465
this . currentAnimation = frameOrAnimation ;
466
466
this . _normalizeFrame ( frame ) ;
467
+ } else {
468
+ console . error ( 'no frame or animation named:' , frameOrAnimation )
467
469
}
470
+
468
471
} else {
469
472
this . currentAnimation = this . _animation = null ;
470
473
this . _currentFrame = frameOrAnimation ;
0 commit comments