Please help test Phaser 2.3.4 Release Candidate 1

Article by Richard Davey. Posted on 21st Aug 2015.   @phaser_

image

Today we've released Phaser 2.3.4 RC1 and we'd greatly appreciate any time you can spend helping to test it.

As to be expected there are a bunch of bug fixes and updates. However we also found time to add some nice new features too:

  • Loader.images is a new method that allows you to pass an array of image keys, and optionally the urls, to the Loader and have them all added to the load queue in one go.
  • TweenManager.frameBased allows you to control if all newly created Tweens update based on the physics step (i.e. frame based) or the system clock (time based). A frame based tween will use the physics elapsed timer when updating. This means it will retain the same consistent frame rate, regardless of the speed of the device. The duration value given should be given in frames. If the Tween uses a time based update (which is the default) then the duration is given in milliseconds. In this situation a 2000ms tween will last exactly 2 seconds, regardless of the device and how many visual updates the tween has actually been through.
  • Tween.frameBased does the same as TweenManager.frameBased but allows you to set the value on a per-tween basis.
  • BitmapText.smoothed is a new boolean property that allows you to set texture smoothing on a bitmap font or not. By default smoothing is always on, but you can turn it off which helps for bitmap fonts created from pixel art style character sets.
  • Text.addFontStyle and Text.addFontWeight allow you to apply font weights and styles to specific characters in a Text object. For example you can now include bold or italics within single Text objects (thanks @jdnichollsc #1950)
  • PIXI.CanvasPool is a new static global created to deal with the issue of resource leaks and continuous DOM node build-up when creating lots of Text or BitmapData objects, or when calling generateTexture on any display object. The CanvasPool will do its best to re-use out dated canvas elements rather than filling up the DOM with new ones.
  • Sprite.setTexture has a new destroyBase parameter - set this to true if you know the base used a generated texture that isn't being used by any other sprites. This will free-up the canvas for further re-use by other calls to generateTexture or Text objects.
  • Line.midPoint will return a Point object where the x and y values correspond to the center (or midpoint) of the Line segment.
  • Line.rotateAround allows you to rotate a Line around the given coordinates (in world space)
  • Line.centerOn will position the Line so that its midpoint lays on the coordinates given.
  • BitmapData.line draws a line to the BitmapData in the color and thickness specified.
  • BitmapData.op is a handy short-code to get and set the canvas global composite operator.
  • BitmapData.drawFull draws the given Game Object or Group to a BitmapData and then recursively iterates through all of its children, including children of Game Objects and Groups. It can draw Text, BitmapText, Sprites, Images, Emitters and Graphics objects. It's perfectly valid to pass in game.world as the parent object, and it will iterate through the entire display list.

If you find any issues please either post in this forum thread, or add them to the Github Issues.

Download Phaser 2.3.4-RC1