|
1 | 1 | # Change Log |
2 | 2 |
|
3 | | -## Unreleased |
| 3 | +## Version 2.19.0 - 23 August 2021 |
4 | 4 |
|
5 | 5 | ### API Changes |
6 | 6 |
|
7 | | -- Tilemap object properties `ellipse`, `gid`, `point`, `polygon`, `polyline`, `properties`, `rectangle`, `template`, and `text` have default values (`false` or `null`). |
8 | | -- Tilemap object `properties` is an object, as in the Tiled JSON v1.1 format (#623). |
9 | | -- Tilemap#createFromObjects() returns an array instead of `undefined`. |
| 7 | +#### Text |
| 8 | + |
| 9 | +- Text height is now calculated from [actualBoundingBoxAscent](https://caniuse.com/mdn-api_textmetrics_actualboundingboxascent) and [actualBoundingBoxDescent](https://caniuse.com/mdn-api_textmetrics_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. |
| 10 | +- The default [Text#testString](https://photonstorm.github.io/phaser-ce/Phaser.Text.html#testString) changed to `|MÂÉQfjq_`. |
| 11 | + |
| 12 | +#### Tilemaps |
| 13 | + |
| 14 | +- [Tilemap object](https://photonstorm.github.io/phaser-ce/global.html#TilemapObject) properties `ellipse`, `gid`, `point`, `polygon`, `polyline`, `properties`, `rectangle`, `template`, and `text` have default values (`false` or `null`). |
| 15 | +- [Tilemap object](https://photonstorm.github.io/phaser-ce/global.html#TilemapObject) `properties` is an object, as in the Tiled JSON v1.1 format (#623). |
| 16 | +- [Tilemap#createFromObjects()](https://photonstorm.github.io/phaser-ce/Phaser.Tilemap.html#createFromObjects) returns an array instead of `undefined`. |
10 | 17 |
|
11 | 18 | ### New Features |
12 | 19 |
|
13 | | -- Tilemap#getObject() gets a tilemap object by `id`, from any object layer. |
14 | | -- Tilemap#getObjects() gets the tilemap objects matching the given property name and value. |
| 20 | +- You can pass `style.fontProperties` when creating a [Text](https://photonstorm.github.io/phaser-ce/Phaser.Text.html) game object or in [Text#setStyle()](https://photonstorm.github.io/phaser-ce/Phaser.Text.html#setStyle). |
| 21 | +- You can pass `style.testString` when creating a [Text](https://photonstorm.github.io/phaser-ce/Phaser.Text.html) game object or in [Text#setStyle()](https://photonstorm.github.io/phaser-ce/Phaser.Text.html#setStyle). |
| 22 | +- [Tilemap#getObject()](https://photonstorm.github.io/phaser-ce/Phaser.Tilemap.html#getObject) gets a tilemap object by `id`, from any object layer. |
| 23 | +- [Tilemap#getObjects()](https://photonstorm.github.io/phaser-ce/Phaser.Tilemap.html#getObjects) gets the tilemap objects matching the given property name and value. |
15 | 24 |
|
16 | 25 | ### Updates |
17 | 26 |
|
18 | | -- When the Tilemap#createFromObjects() `search` argument is an array, e.g. `['type', 'enemy']`, it matches objects with that property name and value. |
19 | | -- When the Tilemap#createFromObjects() `search` argument is `null`, it matches all objects in the layer. |
20 | | -- When the Tilemap#createFromObjects() `group` argument is `null`, it doesn't add the created sprites to a group. |
| 27 | +- When the [Tilemap#createFromObjects()](https://photonstorm.github.io/phaser-ce/Phaser.Tilemap.html#createFromObjects) `search` argument is an array, e.g. `['type', 'enemy']`, it matches objects with that property name and value. |
| 28 | +- When the [Tilemap#createFromObjects()](https://photonstorm.github.io/phaser-ce/Phaser.Tilemap.html#createFromObjects) `search` argument is `null`, it matches all objects in the layer. |
| 29 | +- When the [Tilemap#createFromObjects()](https://photonstorm.github.io/phaser-ce/Phaser.Tilemap.html#createFromObjects) `group` argument is `null`, it doesn't add the created sprites to a group. |
21 | 30 |
|
22 | 31 | ### Bug Fixes |
23 | 32 |
|
24 | | -- 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. |
| 33 | +- [Tilemap#createFromObjects()](https://photonstorm.github.io/phaser-ce/Phaser.Tilemap.html#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. |
25 | 34 |
|
26 | 35 | ## Version 2.18.0 - 7 May 2021 |
27 | 36 |
|
|
0 commit comments