mirror of
https://github.com/photonstorm/phaser
synced 2025-02-17 14:38:30 +00:00
Revert "Allow for chaining multible animations"
This reverts commit a5eacab048
.
This commit is contained in:
parent
a5eacab048
commit
b00acb1838
1 changed files with 2 additions and 15 deletions
|
@ -87,15 +87,6 @@ var Animation = new Class({
|
|||
*/
|
||||
this.nextAnim = null;
|
||||
|
||||
/**
|
||||
* A queue of chained keys of the next Animations to be loaded into this Animation Controller when the current animation completes.
|
||||
*
|
||||
* @name Phaser.GameObjects.Components.Animation#nextAnim
|
||||
* @type {Array}
|
||||
* @default []
|
||||
*/
|
||||
this.nextAnimsQueue = [];
|
||||
|
||||
/**
|
||||
* Time scale factor.
|
||||
*
|
||||
|
@ -330,11 +321,7 @@ var Animation = new Class({
|
|||
key = key.key;
|
||||
}
|
||||
|
||||
if(this.nextAnim === null){
|
||||
this.nextAnim = key;
|
||||
}else{
|
||||
this.nextAnimsQueue.push(key);
|
||||
}
|
||||
this.nextAnim = key;
|
||||
|
||||
return this.parent;
|
||||
},
|
||||
|
@ -863,7 +850,7 @@ var Animation = new Class({
|
|||
{
|
||||
var key = this.nextAnim;
|
||||
|
||||
this.nextAnim = this.nextAnimsQueue.length > 0 ? this.nextAnimsQueue.shift() : null;
|
||||
this.nextAnim = null;
|
||||
|
||||
this.play(key);
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue