|
1 | 1 | # Change Log |
2 | 2 |
|
| 3 | +## Version 3.12.0 - Silica - in development |
| 4 | + |
| 5 | +### New Features |
| 6 | + |
| 7 | +* `Camera.resolution` is a new read-only property that holds the current game config resolution that the camera is using. This is used internally for viewport calculations. |
| 8 | +* `Text.resolution` and the method `Text.setResolution` allows you to control the resolution of a Static Text Game Object. By default it will be set to match the resolution set in the Game Config, but you can override it yourself via the TextStyle. It allows for much clearer text on High DPI devices, at the cost of larger internal Canvas textures for the Text - so please use with caution, as the more high res Text you have, the more memory it uses up. Fix #3528 (thanks @kirillbunin) |
| 9 | +* `TransformMatrix.getCSSMatrix` will return a CSS transform matrix formatted string from the current matrix values. |
| 10 | +* `CacheManager` now creates a new cache called `html` which is used to store all loaded HTML snippets. |
| 11 | +* `FileType.HTML` is a new file type loader that will load an HTML snippet and store it in the new `html` cache. Access it via `load.html` (this method was previously used to load html to textures, please see `load.htmlTexture` for this feature now) |
| 12 | + |
| 13 | +### Updates |
| 14 | + |
| 15 | +* `Camera.x` and `Camera.y` have been turned into getters / setters, mapped to the internal private values `_x` and `_y` respectively. This is so that setting the Camera viewport position directly will now update the new internal resolution calculation vars too. |
| 16 | +* `Camera.setScene` will now set the Cameras `resolution` property at the same time and update the internal viewport vars. |
| 17 | +* The `Cull Tiles` method used by the Dynamic Tilemap Layer has had a nice and significant optimization. It will now use the cull area dimensions to restrict the amount of tile iteration that takes place per layer, resulting in dramatic reductions in processing time on large layers, or multiple layers (thanks @tarsupin) |
| 18 | +* `GameObject.willRender` now takes a Camera as its only argument and uses it within the check. This has allowed me to remove 23 duplicate checks spread across the various Game Objects, all of which did the same thing, saving both KB and CPU time as the flags were being checked twice in most cases. |
| 19 | +* The file type loader `HTML` has been renamed to `HTMLTexture`. If you were using this then please change your calls from `load.html` to `load.htmlTexture`. The arguments remain the same. |
| 20 | + |
| 21 | +### Game Config Resolution Specific Bug Fixes |
| 22 | + |
| 23 | +Setting the `resolution` property in the Game Config to a value other than 1 would cause various errors in the API. The following have been fixed: |
| 24 | + |
| 25 | +* The game canvas would be sized incorrectly, unless you had enabled auto resizing. It now scales the canvas to the size given, maintaining the resolution. Fix #3468 (thanks @Legomite) |
| 26 | +* Cameras with background colors set would display the filled color area at the wrong size. Camera fills now respect the resolution. |
| 27 | +* The Camera Fade Effect would display the fade fill rectangle at the wrong size. Camera fades now respect the resolution. |
| 28 | +* The Camera Flash Effect would display the fade fill rectangle at the wrong size. Camera flashes now respect the resolution. |
| 29 | +* The Camera Shake Effect would shake the Camera using the wrong width values. Camera Shakes now respect the resolution. |
| 30 | +* Input calculations would not factor in the Game Resolution correctly. If a Camera viewport was not at 0x0 or not the full size, or the Camera was rotated or zoomed, the input areas would be wrong if `resolution` was > 1. These are now factored in correctly and changing the resolution no longer breaks input. Fix #3606 (thanks @Secretmapper) |
| 31 | + |
| 32 | +### Bug Fixes |
| 33 | + |
| 34 | +* The `setCrop` method stored its crop object on the prototype chain by mistake, causing all Images or Sprites that were cropped to display the same frame. The crop data has been moved to the Game Object instance, where it should be, fixing this issue (thanks NoxBrutalis) |
| 35 | +* If an AudioFile failed to load and throw an incomplete error, it would cause the console.log to crash JavaScript when trying to log the error. It now only logs the message if it exists. Fix #3830 (thanks @kelostrada) |
| 36 | + |
| 37 | +### Examples, Documentation and TypeScript |
| 38 | + |
| 39 | +My thanks to the following for helping with the Phaser 3 Examples, Docs and TypeScript definitions, either by reporting errors, fixing them or helping author the docs: |
| 40 | + |
| 41 | +@SBCGames |
| 42 | + |
| 43 | +Thanks to @khaleb85 for fixing the super-annoying lag on the API Docs pages when it hung the browser while indexing the search field. |
| 44 | + |
| 45 | + |
3 | 46 | ## Version 3.11.0 - Leafa - 13th July 2018 |
4 | 47 |
|
5 | 48 | ### Camera - New Features, Updates and Fixes |
|
0 commit comments