Skip to content

Commit

Permalink
Merge pull request #701 from photonstorm/release/v2.19.0
Browse files Browse the repository at this point in the history
Release Phaser CE v2.19.0
  • Loading branch information
photonstorm authored Aug 23, 2021
2 parents f098b9c + 7d7638e commit 6aaec33
Show file tree
Hide file tree
Showing 221 changed files with 10,377 additions and 9,073 deletions.
29 changes: 19 additions & 10 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,27 +1,36 @@
# Change Log

## Unreleased
## Version 2.19.0 - 23 August 2021

### API Changes

- 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`.
#### Text

- 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.
- The default [Text#testString](https://photonstorm.github.io/phaser-ce/Phaser.Text.html#testString) changed to `|MÂÉQfjq_`.

#### Tilemaps

- [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`).
- [Tilemap object](https://photonstorm.github.io/phaser-ce/global.html#TilemapObject) `properties` is an object, as in the Tiled JSON v1.1 format (#623).
- [Tilemap#createFromObjects()](https://photonstorm.github.io/phaser-ce/Phaser.Tilemap.html#createFromObjects) returns an array instead of `undefined`.

### New Features

- Tilemap#getObject() gets a tilemap object by `id`, from any object layer.
- Tilemap#getObjects() gets the tilemap objects matching the given property name and value.
- 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).
- 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).
- [Tilemap#getObject()](https://photonstorm.github.io/phaser-ce/Phaser.Tilemap.html#getObject) gets a tilemap object by `id`, from any object layer.
- [Tilemap#getObjects()](https://photonstorm.github.io/phaser-ce/Phaser.Tilemap.html#getObjects) gets the tilemap objects matching the given property name and value.

### Updates

- When the Tilemap#createFromObjects() `search` argument is an array, e.g. `['type', 'enemy']`, it matches objects with that property name and value.
- When the Tilemap#createFromObjects() `search` argument is `null`, it matches all objects in the layer.
- When the Tilemap#createFromObjects() `group` argument is `null`, it doesn't add the created sprites to a group.
- 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.
- 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.
- 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.

### 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.
- [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.

## Version 2.18.0 - 7 May 2021

Expand Down
18 changes: 9 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Phaser CE is a fast, free, and fun open source HTML5 game framework. It uses a c

Phaser CE is based on Phaser v2.6.2 by [Photon Storm](http://www.photonstorm.com). [Phaser v3](http://phaser.io/phaser3) and [Phaser v4](https://github.com/phaserjs/phaser4) are in active development.

The [current Phaser CE release is 2.18.0](https://github.com/photonstorm/phaser-ce/releases/tag/v2.18.0).
The [current Phaser CE release is 2.19.0](https://github.com/photonstorm/phaser-ce/releases/tag/v2.19.0).

- **Visit:** The [Phaser website](http://phaser.io) and follow on [Twitter](https://twitter.com/photonstorm) (#[phaserjs](https://twitter.com/hashtag/phaserjs))
- **Learn:** [API Docs](https://photonstorm.github.io/phaser-ce/), [Support Forum][forum] and [StackOverflow](https://stackoverflow.com/questions/tagged/phaser-framework)
Expand Down Expand Up @@ -82,19 +82,19 @@ Please see additional steps for [Browserify/CommonJS](#browserify) and [Webpack]
[Phaser CE is on jsDelivr](http://www.jsdelivr.com/projects/phaser-ce). Include the following in your html:

```html
<script src="https://cdn.jsdelivr.net/npm/phaser-ce@2.18.0/build/phaser.js"></script>
<script src="https://cdn.jsdelivr.net/npm/phaser-ce@2.19.0/build/phaser.js"></script>
```

or the minified version:

```html
<script src="https://cdn.jsdelivr.net/npm/phaser-ce@2.18.0"></script>
<script src="https://cdn.jsdelivr.net/npm/phaser-ce@2.19.0"></script>
```

[Custom builds](https://cdn.jsdelivr.net/npm/phaser-ce@2.18.0/build/custom/) are available too, e.g.,
[Custom builds](https://cdn.jsdelivr.net/npm/phaser-ce@2.19.0/build/custom/) are available too, e.g.,

```html
<script src="https://cdn.jsdelivr.net/npm/phaser-ce@2.18.0/build/custom/phaser-arcade-physics.js"></script>
<script src="https://cdn.jsdelivr.net/npm/phaser-ce@2.19.0/build/custom/phaser-arcade-physics.js"></script>
```

<a name="getting-started"></a>
Expand Down Expand Up @@ -282,10 +282,10 @@ All rights reserved.

[![Analytics](https://ga-beacon.appspot.com/UA-44006568-2/phaser/index)](https://github.com/igrigorik/ga-beacon)

[get-js]: https://github.com/photonstorm/phaser-ce/releases/download/v2.18.0/phaser.js
[get-minjs]: https://github.com/photonstorm/phaser-ce/releases/download/v2.18.0/phaser.min.js
[get-zip]: https://github.com/photonstorm/phaser-ce/archive/v2.18.0.zip
[get-tgz]: https://github.com/photonstorm/phaser-ce/archive/v2.18.0.tar.gz
[get-js]: https://github.com/photonstorm/phaser-ce/releases/download/v2.19.0/phaser.js
[get-minjs]: https://github.com/photonstorm/phaser-ce/releases/download/v2.19.0/phaser.min.js
[get-zip]: https://github.com/photonstorm/phaser-ce/archive/v2.19.0.zip
[get-tgz]: https://github.com/photonstorm/phaser-ce/archive/v2.19.0.tar.gz
[clone-http]: https://github.com/photonstorm/phaser.git
[clone-ssh]: ssh://[email protected]:photonstorm/phaser.git
[clone-svn]: https://github.com/photonstorm/phaser
Expand Down
2 changes: 1 addition & 1 deletion build/custom/creature.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion build/custom/p2.min.js

Large diffs are not rendered by default.

Loading

0 comments on commit 6aaec33

Please sign in to comment.