Repository navigation
Added
- State: a
"pixelate"transition,state.transition("pixelate", color, duration, size): the screen breaks into growing blocks and comes back sharp. Skipped on Canvas
Fixed
- Rendering: with
subPixeloff, each draw snaps to whole pixels once, where it lands, the same on Canvas, WebGL and WebGPU (#1765). Something at a fractional position can draw one pixel over - Camera: with
subPixeloff,worldView,localToWorldandworldToLocaluse the view position rounded to a whole pixel, where the world is drawn from - Geometry: the methods taking a point (
translate,shift,contains) take any object withxandy, such as a renderable'spos, instead of returningNaN - Physics: a body with several shapes has the union of its shapes as its bounds; each shape added shifted them
- Physics:
Body#setVerticeson one of several shapes keeps the body's bounds andpseudoInertiaright (set it again if you set it by hand), and throws aRangeErrorpast the last shape - Physics: a body that drops its last
Box3dorSphereno longer resolves along z - Loader: the default loading screen shows its progress bar and logo in the same frame
- ImageLayer: a repeating layer keeps covering the screen however far the camera moves, instead of sliding off
- Animation: a one-frame animation played once completes, so
onCompletefires andnextis followed - Audio:
audio.setListener(app.viewport)hears from the center of the camera's view, not its top-left corner - Input:
input.bindPointerkeeps its bindings once the mouse enters the canvas - Audio: a clip with
preload: falseis fetched and streamed when first played; it never played (#1784) - State: the first frame of a new stage or level shows its world, not the background alone
- State: a
state.change()asked for during a transition is made by that transition, instead of leaving the screen black (#1787) - Effects: the built-in effects that place a pattern (sway, wave, vignette, gradient, scanline, shine) place it on the sprite, also cut from an atlas or with other effects after it (#1407)
- Effects: a renderable drawn through two or more effects keeps its opacity on WebGL and WebGPU (#1791)
- Effects: through two or more effects, widths, offsets and sizes are in the renderable's own pixels at any scale or zoom, as with one effect. Check widths tuned on a scaled renderable
- Effects: a renderable drawn through two or more effects stays inside its clip, such as a minimap camera's view, instead of spilling over the canvas
- Effects: on WebGPU, effects read their capture at the game's texture filter, as on WebGL, so pixel-art games stay crisp
- Input: a gamepad unplugged while a button or the stick is held lets go of the keys bound to them, instead of leaving them pressed
- Input: a stick with only one side bound lets go of its key when it returns to the centre or rests just past it, instead of holding it until pushed that way again
- Lighting: a
Light2d's glow and the darkness around it compile when the light is added to the world, not inside the first frame that draws it - Typings:
TextureAtlas#createAnimationFromNamedeclares both of its arguments optional, as they are at runtime, and is documented again
Full Changelog: 20.11.0...20.12.0