2.4 KiB
2.4 KiB
Phaser 3.60.0 Change Log
Return to the Change Log index.
Animation System New Features
AnimationManager.getAnimsFromTextureis a new method that will return all global Animations, as stored in the Animation Manager, that have at least one frame using the given Texture. This will not include animations created directly on local Sprites.Animation.showBeforeDelayis a new optional boolean property you can set when creating, or playing an animation. If the animation has a delay before playback starts this controls if it should still set the first frame immediately, or after the delay has expired (the default).- You will now get a warning from the
AnimationManagerandAnimationStateif you try to add an animation with a key that already exists. Fix #6434.
Animation System Updates
Animation.stopis always called when a new animation is loaded, regardless if the animation was playing or not and thedelayCounteris reset to zero. This stops animations with delays preventing other animations from being started until the delay has expired. Fix #5680 (thanks @enderandpeter)Animations.AnimationManager.createFromAsepritehas a new optional 3rd parametertarget. This allows you to create the animations directly on a Sprite, instead of in the global Animation Manager (thanks Telemako)Animations.AnimationState.createFromAsepriteis a new method that allows you to create animations from exported Aseprite data directly on a Sprite, rather than always in the global Animation Manager (thanks Telemako)
Animation System Bug Fixes
- When playing a chained animation, the
nextAnimproperty could get set toundefinedwhich would stop the next animation in the queue from being set. The check now handles all falsey cases. Fix #5852 (thanks @Pythux) Animation.createFromAsepritewould calculate an incorrect frame duration if the frames didn't all have the same speed.- The frame duration calculations in the
AnimationManager.createFromAsepritemethod would be incorrect if they contained a mixture of long and very short duration frames (thanks @martincapello)
Return to the Change Log index.
📖 Read the Phaser 3 API Docs 💻 Browse 2000+ Code Examples 🤝 Join the awesome Phaser Discord