Update dependency phaser to v3.88.2 #380
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
3.86.0->3.88.2Release Notes
phaserjs/phaser (phaser)
v3.88.2: Phaser v3.88.2Compare Source
Bug Fixes
autoCenter: Phaser.Scale.CENTER_BOTHfrom working.v3.88.1: Phaser v3.88.1Compare Source
Bug Fixes
ReferenceError: GetFastValueOp is not definedin NumberTweenBuilder (thanks Flow)SafeRangearray util function.Array.Utils.GetFirstso it correctly handles a negative start index. Fixes Container.getByName returning null and various other similar methods. Fix #7040 (thanks @XWILKINX)v3.88.0: Phaser v3.88Compare Source
New Features
Transform.getWorldPointis a new method that will return the World point as a Vector2 of a Game Object, factoring in parents if applicable (thanks @samme)Utils.Array.GetFirstcan now search from the end of the array when settingstartIndexto -1.DynamicTextureand by extensionRenderTexturenow have a new boolean propertyforceEvenin their constructor,setSizeandresizemethods. This will force the given width and height values to be rounded up to the nearest even value. This significantly improves the rendering quality of the render texture in most circumstances, so the flag istrueby default. This is a potentially breaking change, so if you know you need an odd sized texture, please set the value tofalse. Fix #6988 (thanks @rexrainbow)Updates
Tween.isNumberTweenis a new boolean property that tells if the Tween is a NumberTween, or not.TransformMatrix.setTransformmethod has been updated so that it uses the old way of passing in matrix values for Canvas 2D. This fixes the error "Failed to execute 'setTransform' on 'CanvasRenderingContext2D': 6 arguments required, but only 1 present." in old legacy browsers such as Chromium Embedded Framework. Fix #6965 (thanks @rafa-fie)mousedownandmouseuphave been added for unlocking Web Audio. Both events occur before aclickevent, allowing for earlier audio unlocking on devices that use a mouse (thanks @pavle-goloskokovic)addBase64method. Rather than the error "TypeError: null is not an object (evaluating 'texture.source')" is will not return early (thanks @samme)TweenBuilderandNumberTweenBuilderhave been updated to useGetFastValuefor most properties instead ofGetValue.Transform.getWorldTransformMatrixmethod will now destroy the parent matrix at the end, if it was created within the method.Body.setGameObjectandStaticBody.setGameObjectmethods have been updated to do the following: Return if no valid Game Object is passed. Disable and null the body of the existing Game Object if the Body has one. Set thebodyproperty, even if it doesn't exist (converts non-physics objects into physics objects). CallssetSizeto update the body dimensions to make the new Game Object and finally setsenablebased on the given parameter, which is now correctly referenced. The StaticBody version also has a new parameter,enablewhich matches that of the Dynamic Body and defaults totrue(the original state). Fix #6969 (thanks @yongzheng7)ArcadeColliderTypehas been updated to includePhysics.Arcade.StaticBody. Fix #6967 (thanks @yongzheng7)Phaser.Types.GameObjects.Text.TextStylenow includesletterSpacing: a positive or negative amount to add to the spacing between characters. Fix #7002 (thanks @Stever1388)Tilemaps.Parsers.Tiled.ParseTilesets,Tilemaps.Parsers.Tiled.BuildTilesetIndexandTilemaps.ImageCollection.addImagehave been updated to includewidthandheightof each individual image. Fix #6990 (thanks @stickleprojects)Tilemaps.Components.RenderDebugandTilemaps.Parsers.Tiled.BuildTilesetIndexhave been updated to includewidthandheightoffsets in Image Collections.Tilemaps.Components.GetTilesWithinShapewhen attempting to use this method with non orthogonal tilemaps.Cameras.Scene2D.Camera.preRendermethod from protected to public. Fix #7020 (thanks @zoubingwu)Bug Fixes
TweenData.updatewill now check if the Tween is a Number Tween and apply the final start/end value to the result on completion, instead of the eased value as calculated by the change made in v3.87.BaseTweenData.durationcan now never be zero or less than zero, which would trigger NaN errors. It's now clamped to a minimum of 0.01ms. Fix #6955 (thanks @kainage)FontFileConfig(thanks @samme)Matter.World.updatecould hang and crash the browser if a large delta value was given to it, such as returning to a long-dormant tab. The Matter Runner config values are now properly passed through, preventing this from happening. Fix #6977 (thanks @ubershmekel @samme)Phaser.Physics.Matter.Components.Transform#scalecorrectly scales the physics body with the GameObject. Fix #7001 (thanks @Stever1388)Phaser.Textures.Frame.setCropUVsupdated crop calculation to include thespriteSourceSize. Fix #6996 (thanks @CrispMind)Phaser.Tilemaps.Parsers.Tiled.ParseJSONTiledupdated hexagonal tilemaps to correctly calculate thewidthInPixelsandheightInPixelsbased on the hexagonal overlapping tiles. Fix #6992 (thanks @ptantiku)Phaser.Display.Color.Interpolate.RGBWithRGBnow correctly returns aPhaser.Types.Display.ColorObjectthat includesr,g,b,aandcolorvalues. Fix #6979 (thanks @XWILKINX)Phaser.Plugins.PluginManagerautomatically boots plugins when the game config render type is set toPhaser.HEADLESS. Fix #6893 (thanks @hubertgrzeskowiak)persistset totrueand given acompleteDelayvalue are no longer destroyed and can be replayed. Fix #7008 (thanks @Stever1388)Tweens.TweenChainonStartevent is now dispatched properly. Fix #7007 (thanks @Stever1388)GameObjects.Particles.Zones.DeathZonenow uses world position coordinates instead of local position coordinates following the particle emitter position. Fix #7006 (thanks @Stever1388)Phaser.Types.Tweens.TweenBuilderConfigobject is now correctly executed without errors. Fix #7003 (thanks @Stever1388)GameObjects.Textcreated withwordwrapand withletterSpacingapplied now takes into account the providedletterSpacingvalue to correctly wrap lines. Fix #7002 (thanks @Stever1388)GameObjects.DOMElementsets the GameObject'sdisplayWidthanddisplayHeightusing itsscaleXandscaleYvalues instead of the DOM elementsgetBoundingClientRect()values. Fix #6871 (thanks @HawkenKing)modetoPhaser.Scale.FITandautoCentertoPhaser.Scale.CENTER_BOTHcorrectly centres canvas on iOS devices. Fix #6862 (thanks @HawkenKing)Tilemaps.Tilemap.createBlankLayermethod now correctly sets thehexSideLengthas loaded from the hex tilemap. Fix #6074 (thanks @wwoods)Input.InputPlugin.processDragUpEventnow correctly returnsxandycoordinates in world space.Animations.AnimationState.playmethod now prioritises theframeRateproperty when it is set in thePlayAnimationConfigobject over animation data loaded from an external file.LayerGame Object methodsetToTopwould throw an exception:getDisplayList is not a function. This method has now been added to the Game Object. Fix #7014 (thanks @leha-games @rexrainbow)EmitterOpdefaultEmit()always returnedundefined, causing particle problems if you gave only anonUpdatecallback. Also if you configured an EmitterOp withonEmitoronUpdate, the op's current value would be incorrect (an object) until the first emit. Fix #7016 (thanks @urueda @samme)Examples, Documentation, Beta Testing and TypeScript
Thanks to the following for helping with the Phaser Examples, Beta Testing, Docs, and TypeScript definitions, either by reporting errors, fixing them, or helping author the docs:
@samme
@justin-calleja
v3.87.0: Phaser v3.87Compare Source
New Features
FontFileis a new File Type loader that allows you to load TTF/OTF fonts directly into Phaser, without the need for a 3rd party web font loader or CSS hacks. The loaded fonts can be used in the Text Game Objects, such as the example below:Updates
animproperty exists within the emitter configuration. By not creating the controller it leads to less memory overhead and a much faster clean-up time when destroying particles. Fix #6482 (thanks @samme)TweenData.updateto achieve the same result with my less repetition. Also fixes an issue where a Tween that used a customeasecallback would glitch when the final value was set, as it would be set outside of the ease callback. It's now passed through it, no matter what. Fix #6939 (thanks @SBCGames)Bug Fixes
GetBitmapTextSizethat would lead to incorrect indexes vs. the docs and previous releases (thanks @bagyoni)Utils.String.RemoveAtwould incorrectly calculate the slice index if it was > 0. It will now remove the correctly specified character.Examples, Documentation, Beta Testing and TypeScript
Thanks to the following for helping with the Phaser Examples, Beta Testing, Docs, and TypeScript definitions, either by reporting errors, fixing them, or helping author the docs:
@Jessime
@drakang4
@BenAfonso
@hatchling13
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.