Phaser Ce Versions Save

Phaser CE is a fun, free and fast 2D game framework for making HTML5 games for desktop and mobile web browsers, supporting Canvas and WebGL rendering.

v2.20.0

1 year ago

Version 2.20.0 - 10 December 2022

API Changes

  • Removed Phaser.GAMES.
  • Removed PIXI.defaultRenderer.
  • Removed PIXI.game.
  • Phaser.Game#isRunning has changed slightly: it now changes from false to true when the core game loop starts running and to false when the game is destroyed.

New Features

  • Phaser.Game#onDestroy is a new signal that is fired at the beginning of the game destroy sequence.
  • Phaser.CanvasPool.clear() empties the canvas pool.

Updates

  • Phaser.Utils.Debug now has all its methods stubbed when disabled.
  • There's a console message reminding you to disable the debug canvas in production, if it's enabled. You can disable it by passing { enableDebug: false } in the game config or making a custom build of Phaser CE without the debug module.
  • When the game is destroyed, its signals are disposed, more properties are nullified, and isBooted and isRunning change to false.

Bug Fixes

  • Fixed incorrect result in Phaser.Point.multiplyAdd().
  • Fixed Phaser.Rope appearing in the Canvas renderer when invisible.
  • Fixed an error destroying the game before it's booted (#728).
  • Fixed an error creating a RenderTexture after destroying the game (#729).

Thanks

@gm0nk, @timiyay

v2.19.2

2 years ago

Version 2.19.2 - 24 October 2021

Bug Fixes

  • Fixed a WebGL error (#709).

Thanks

@photonstorm, @XWILKINX

v2.19.1

2 years ago

Version 2.19.1 - 13 October 2021

Bug Fixes

  • TilemapLayer#getRayCastTiles() was less efficient and behaved incorrectly for horizontal or vertical rays.
  • Text no longer errors when missing a style parameter.
  • Fixed some WebGL warnings.

Thanks

@noocsharp

v2.19.0

2 years ago

API Changes

Text

  • Text height is now calculated from actualBoundingBoxAscent and actualBoundingBoxDescent where available or estimated from character widths otherwise. If you need uniform display across devices, it's best to pass style.fontProperties when creating a Text object.
  • The default Text#testString changed to |MÂÉQfjq_.

Tilemaps

  • Tilemap object properties ellipse, gid, point, polygon, polyline, properties, rectangle, template, and text have default values (false or null).
  • Tilemap object properties is an object, as in the Tiled JSON v1.1 format (#623).
  • Tilemap#createFromObjects() returns an array instead of undefined.

New Features

Updates

Bug Fixes

  • Tilemap#createFromObjects() was adjusting y-coordinates for all tile objects, which was incorrect. Now it adjusts y-coordinates for tile objects only, which have origin (0, 1) in Tiled.

v2.18.0

3 years ago

Version 2.18.0 - 7 May 2021

Updates

Bug Fixes

Thanks

@drfrankius, @photonstorm, @samme

v2.17.0

3 years ago

Version 2.17.0 - 16 March 2021

API Changes

The core game loop and timekeeping have been redone. Game timing should now work consistently at any device frame rate, for any desiredFps, with forceSingleUpdate on or off.

Animations, lifespan, particles, physics, timers, and tweens now all use the same delta time, represented by delta and deltaTotal. The delta is scaled by slowMotion. There's no need to adjust desiredFps to match slowMotion now; they work independently. The delta size is clamped by deltaMax, which can be controlled by desiredMinFps as well.

Phaser.Game#forceSingleUpdate now switches between a variable-step or fixed-step game loop.

When forceSingleUpdate is on (the default), the game makes one logic update and one render per animation frame received from the device. This is usually at 60Hz, but can be lower (33Hz) or higher (75Hz, 144Hz, 240Hz).

When forceSingleUpdate is off, the game makes logic updates only at the rate given by desiredFps (60Hz or 16.6ms by default). Depending on the desiredFps value and the device frame rate, this will make zero, one, or several logic updates per animation frame. There is one render per animation frame only if at least one update was made or forceSingleRender is on; otherwise there is none.

See the Phaser CE game loop plot example to try these out.

Added

  • Phaser.Game#onBoot is a signal dispatched after the game boots but before the first update is made. You could use it to configure the game before a game state is started.
  • Phaser.Particles.Arcade.Emitter#setGravity() sets the gravity of emitted particles.
  • Phaser.Particles.Arcade.Emitter#setSpeed() sets the speed ranges of emitted particles.
  • Phaser.Time#delta is the time step for the current logic update, in game time.
  • Phaser.Time#deltaMax is the desired maximum delta size in ms. The default is 200ms.
  • Phaser.Time#deltaTotal is the cumulative delta, so the current "time" in game time.
  • Phaser.Time#desiredMinFps is the desired minimum logic update rate. It sets deltaMax. The default is 5.
  • PIXI.CanvasRenderer#postRender
  • PIXI.WebGLRenderer#postRender

Changed

  • Phaser.Game#dropFrames skips updates and renders when the animation frame interval is larger than deltaMax. It's probably not very useful.
  • Phaser.Game#forceSingleUpdate switches between a variable-step or fixed-step game loop.

Removed

  • Phaser.Game#maxUpdates
  • Phaser.Game#net (game.net)
  • Phaser.Net
  • Phaser.Time#physicsElapsed
  • Phaser.Time#physicsElapsedMS
  • Phaser.Time#prevTime
  • Phaser.Timer#timeCap
  • Phaser.Tween#frameBased
  • Phaser.TweenManager#frameBased
  • The elapsedTime argument in Phaser.State#preRender

Bug Fixes

  • Fixed some errors when destroying a game while Web Audio sounds were decoding (#684).
  • Fixed tweens running at different speeds depending on device frame rate (#685).
  • Fixed incorrect step interval when using setTimeout() (#687)

Thanks

@jf-m, @photonstorm, @samme

v2.16.2

3 years ago

Change Log

Version 2.16.2 - 8 March 2021

Updates

  • Better parsing of Tiled object properties (#682)

Bug Fixes

  • Web Audio sounds will not progress while the audio context is suspended.

Deprecated

These will be removed in v2.17.0:

Thanks

@f0rdP3rf3ct, @photonstorm, @samme

v2.16.1

3 years ago

New Features

Updates

  • Removed the codec parameter for the Phaser.Device#wav test because it gave a false negative in Safari.

Thanks

@jorginius, @photonstorm, @samme

v2.16.0

3 years ago

API Changes

New Features

Updates

  • The Web Audio context is resumed automatically when resuming or refocusing the game (#667).

Thanks

@samme, @SBCGames

v2.15.1

3 years ago

New Features

Updates

Bug Fixes

  • Input pointers are stopped for the 'pointercancel' event. This should prevent lost/frozen pointers after OS gestures (#663).
  • Destroying the game during loading does not cause an error when loader completes (#666).

Thanks

@jf-m, @samme