File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -262,7 +262,7 @@ Phaser.Animation.prototype = {
262262 reverseOnce : function ( ) {
263263 this . reverse ( ) ;
264264
265- this . onComplete . addOnce ( this . reverse . bind ( this ) )
265+ this . onComplete . addOnce ( this . reverse . bind ( this ) ) ;
266266 } ,
267267
268268 /**
Original file line number Diff line number Diff line change @@ -262,6 +262,14 @@ declare module "phaser" {
262262 */
263263 reverse(): void;
264264
265+ /**
266+ * Reverses the animation direction for the current/next animation only
267+ * Once the onComplete event is called this method will be called again and revert
268+ * the reversed state.
269+ */
270+ reverseOnce(): void;
271+
272+
265273 /**
266274 * Sets this animations playback to a given frame with the given ID.
267275 *
Original file line number Diff line number Diff line change @@ -92,6 +92,7 @@ declare module "phaser" {
9292 previous ( quantity ?: number ) : void ;
9393 restart ( ) : void ;
9494 reverse ( ) : void ;
95+ reverseOnce ( ) : void ;
9596 setFrame ( frameId ?: string | number , useLocalFrameIndex ?: boolean ) : void ;
9697 stop ( resetFrame ?: boolean , dispatchComplete ?: boolean ) : void ;
9798 update ( ) : boolean ;
You can’t perform that action at this time.
0 commit comments