The latest version of Phaser is out, along with lots of site updates.

Article by Richard Davey. Posted on 15th Oct 2015.   @phaser_

image

I'm pleased to announce the immediate availability of Phaser 2.4.4 ("Amador").

This release concludes all of our recent work on new features, updates and bug fixes. We've been testing this one for quite some time now. Lots of the new features and fixes are a direct result of when we wrote the Interphase book, as well as the new Particle Storm plugin.

Just a few of the new features include:

  • Audio unlocking fixed on iOS9.
  • Emitter.emitParticle now has 4 new optional arguments: x, y, key and frame. These allow you to override whatever the Emitter default values may be and emit the particle from the given coordinates and with a new texture.
  • Group.getFirstDead, Group.getFirstAlive and Group.getFirstExists all have new optional arguments: createIfNull, x, y, key and frame. If the method you call cannot find a matching child (i.e. getFirstDead cannot find any dead children) then the optional createIfNull allows you to instantly create a new child in the group using the position and texture arguments to do so. This allows you to always get a child back from the Group and remove the need to do null checks and Group inserts from your game code. The same arguments can also be used in a different way: if createIfNull is false AND you provide the extra arguments AND a child is found then it will be passed to the new Group.resetChild method. This allows you to retrieve a child from the Group and have it reset and instantly ready for use in your game without any extra code.
  • Tiled 0.13.0 added support for layer data compression when exporting as JSON. This means that any .tmx stored using base64 encoding will start exporting layer data as a base64 encoded string rather than a native array. This update adds in automatic support for this as long as the data isn't compressed. For IE9 support you'll need to use the new polyfill found in the resources folder (thanks @noidexe #2084)
  • You can now load single layer Pyxel Edit TileMaps as an atlas (thanks @joshpmcghee #2050)

Along with lots more. You can read them all on the releases page (link below) or on GitHub.

We've also spent some time tidying up the Phaser Examples. All Examples now use Phaser 2.4.4 by default, and the Phaser version switcher works properly now. Also the 'Rocket icon' above the code editor, that allowed you to edit the source code on the Examples pages and re-run it, has been fixed. It will now honor the version of Phaser currently selected and re-run against that.

The Examples site was also using an out-dated build of 2.4.3, which has been corrected. A bunch of new Examples have been imported across various categories, including this super-useful Sprite Pivot example.

Finally the Phaser Sandbox has also been updated for 2.4.4 as well.

As always thank you to all of those who contributed towards this release, either via code or bug reports. Also thank you to the Phaser patreons - your contributions allowed me to spend the time needed doing all the work required for a release.

As we head in to the last quarter of 2015 we'll continue work on bug fixing and supporting Phaser 2, along with carrying on development on both the Phaser 3 and Phaser Nano projects.

Read More