Skip to content

Releases: melonjs/melonJS

v13.0.0

18 Jul 06:47
Compare
Choose a tag to compare

added

  • Event: also provide a reference to the camera viewport being resized when emitting VIEWPORT_ONRESIZE
  • Unit Test: added base64 encoded data preload testing for image and audio assets
  • Utils: new isDataUrl() helper returning true if the given url is in the data:[<mediatype>][;base64],<data> format.

Changed

  • Core: full ES6 refactoring of me.device, and API clean-up (@see https://github.com/melonjs/melonJS/wiki/Upgrade-Guide#120x-to-130x-stable)
  • Game: refactoring of the global game into an instantiable Application object, with game now being the default instance of it (@see #1091)
  • Loader: onload and onerror callbacks are now optionals when directly loading assets (easier with base64 encoded assets)
  • Physic: World physic implementation is now properly tight to its corresponding parent application/game (@see #1091)
  • Physic: Gravity is now properly applied as a force, instead of directly modifying a body velocity
  • Physic: Gravity now properly takes in account the body mass
  • Physic: resulting force is now properly cancelled at the end of an update cycle (not required anymore to manually set it to 0 in user code)

Fixed

  • Doc: fix missing Timer documentation following previous refactoring
  • Loader: fix loading/preloading of base64 audio assets, and base64 encoded FontFace
  • Renderer: fix a regression with the masking features in the Canvas Rendering mode
  • Text: fix an uncaught exception when removing Text object from the game world that use offScreenCanvas texture caching (thanks @wpernath)

v12.0.0

27 Jun 06:14
Compare
Choose a tag to compare

this release mostly contains the new melonjs logo/rebranding.

Changed

  • Loader: the default loading screen has been updated with the new melonjs logo
  • String: replaced own trim[left/right] functions with native es10 equivalent (with polyfill)

v11.0.0

23 Jun 09:03
Compare
Choose a tag to compare

Added

  • Event: new DOM_READY event triggered when the DOM is loaded and ready (now used internally to trigger the onReady() function)

Changed

  • Renderable: update the Light2d constructor to allow creating elliptical shaped lights

Fixed

  • Core: fix an uncaught exception when using parcel (thanks @8Observer8)

v10.12.0

20 Jun 00:38
Compare
Choose a tag to compare

Added

  • State: new get(state) function that return the instance to the Stage associated with the given state

Changed

  • Physic: simplify the collision api and implementation (removed collision.response that serves no purpose anymore)
  • Pooling: silently fail if internally failing at recycling body physic shapes

Fixed

  • Physic: fix a regression with Ellipse vs Polygon SAT collision detection
  • Text: make sure the optional x and y arguments of the draw method are set to a default value
  • TypeScript: fix and uniform draw method signature across all renderables
  • TypeScript: fix typings for the onCollision method
  • TypeScript: fix setMaxVelocity and setFriction method scope
  • Webdoc: fix wrong or missing argument names (Path2D.arcTo, Rect.centerOn, Texture.AdduVs)

v10.11.0

14 Jun 01:33
Compare
Choose a tag to compare

Changed

  • Core: fix all rollup "$1" related duplicated declaration and/or export
  • Core: refactored Timer into an instantiable class with timer (namespace) now being the default instance of the Timer class
  • Doc: replaced JSDoc by Webdoc for documentation generation (huge thanks to @ShukantPal)

Fixed

  • Bounds: fix the addFrame() method
  • Core: fix a regression when accessing localStorage
  • Core: fix a regression when when running melonJS in node.js (undefined global reference in the roundRect polyfill)
  • Geometry: fix the RoundRect clone() method
  • Input: fix PointerEvent detection on Firefox for Android mobile (thanks @kutyamutya)
  • Renderer: fix a regression with strokeLine() in the CanvasRenderer

v10.10.0

07 Jun 00:56
Compare
Choose a tag to compare

Added

  • Core: new CanvasTexture object to allow recycling canvas through the engine (text caching, default particles, effect, etc..)
  • Core : new experimental light effect that simply simulate a spot/point light for now (work in progress)
  • Color : allow overriding the alpha component with a specific value when calling toRGBA or toHex8
  • Renderer: support reverse clipping when applying geometry masks (alpha component of the masked area is ignored in legacy Canvas rendering mode)
  • Renderer: added multiple clipping region for masks (only works with overlapping region in legacy Canvas rendering mode)

Changed

  • TMX: replace use of eval() by Function() when parsing map including executable code
  • Core: replace internal calls to deprecated substr function with slice

Fixed

  • Renderable: mark renderable(s) as dirty when their pos or bounds are updated
  • Geometry: fix a regression with roundRect shape drawing

v10.9.0

21 May 01:37
Compare
Choose a tag to compare

Added

  • Geometry : add a proper contains and other utility methods to RoundRect

Fixed

  • Renderer: fix clipping of RoundRect mask with the Canvas Renderer

v10.8.0

16 May 04:34
Compare
Choose a tag to compare

Added

  • Geometry : new RoundRect geometry object
  • Geometry : new Path2D API to provide better abstraction when drawing primitives in WebGL

changed

  • Renderer: refactored the WebGL renderer to use the new Path2D API for primitive drawing

Fixed

  • Core: improve internal object recycling, to fix instance leaking or hoarding by the pool system
  • Input: fix a warning on using passive target disabling swipe on a WebView (thanks @Zngb)

v10.7.1

05 May 01:18
Compare
Choose a tag to compare

Fixed

  • Renderer: fix a crash on context restore when using the canvas renderer

v10.7.0

04 May 07:28
Compare
Choose a tag to compare

Added

  • Core : new device.nodeJS to detect if running under node.js
  • Particle Emitter: added the possibility to define a specific tint and blend mode for particles
  • Renderable: new centerOn method to center a renderable around given coordinates
  • Renderer: added "additive" as an alias for the "lighter" blend mode
  • Renderer: listen to contextlost & contextrestored events in Canvas rendering mode (@see https://developer.chrome.com/blog/canvas2d/#context-loss)

Changed

  • Core : replace internal use of global window object by globalThis
  • Core : refactor the boot process, and device/feature detection/initialisation to better work within node.js (will still require jsdom and node-canvas)
  • Particle Emitter: refactoring of the Emitter class to directly extend Container instead of Renderable

Fixed

  • Particle Emitter: fix a regression in ParticleEmitter causing a crash, after es6 class reformatting
  • Particle Emitter: fix particle additive blend mode in WebGL