Skip to content

Commit

Permalink
StateManager.restart incorrectly skipped the first additional paramet…
Browse files Browse the repository at this point in the history
…er after clearCache (thanks @mariusbrn, fix #722)
  • Loading branch information
photonstorm committed Apr 14, 2014
1 parent 25a93cf commit eeff786
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ Version 2.0.4 - "Mos Shirare" - in development
* Fixed the use of the destroy parameter in Group.removeAll and related functions (thanks @AnderbergE, fix #717)
* P2.World.convertTilemap now correctly checks the collides parameter of the tiles as it converts them.
* Animation.destroy didn't correctly clear the onStart, onLoop and onComplete signals.

* StateManager.restart incorrectly skipped the first additional parameter after clearCache (thanks @mariusbrn, fix #722)


There is an extensive [Migration Guide](https://github.com/photonstorm/phaser/blob/master/resources/Migration%20Guide.md) available for those converting from Phaser 1.x to 2.x. In the guide we detail the API breaking changes and approach to our new physics system.
Expand Down
4 changes: 2 additions & 2 deletions src/core/StateManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -275,9 +275,9 @@ Phaser.StateManager.prototype = {
this._clearWorld = clearWorld;
this._clearCache = clearCache;

if (arguments.length > 3)
if (arguments.length > 2)
{
this._args = Array.prototype.splice.call(arguments, 3);
this._args = Array.prototype.splice.call(arguments, 2);
}

},
Expand Down

0 comments on commit eeff786

Please sign in to comment.