Fork me on GitHub

Fresh & Lightweight

melonJS is an open source HTML5 game engine that empowers developers and designers to focus on content.

The framework provides a collection of composable entities and support for a number of third-party tools. Giving you a powerful combination that can be used wholesale or piecemeal.

Download Read The Docs »

Try Me!


Use the following keys to start playing a simple game built with melonJS. Try it with a gamepad!

KeyAction
W SpacebarJump
AWalk Left
SDrop Down
DWalk Right
FFull-Screen Mode
EscExit Game

See you in a bit!

melonJS is a lightweight yet powerful HTML5 framework designed from the ground up to provide a true plugin-free 'write-once, run-everywhere' gaming platform. melonJS is an open-source project and supported by a community of enthusiasts. See our Gallery for a few examples of games powered by melonJS.

Getting Started


Fast

HTML5

Built with future technology.

  • WebGL
  • WebAudio
  • ES6 Collections

Free

Released under the permissive MIT License.

No cost.

Royalty free.

Forever.

Elegant

Your scene graph is a hierarchy of containers.

Updates and drawing operations are dispatched separately.

Draws are opt-in; add compute-only entities for AI, special effects, etc.

Powerful Level Design


melonJS integrates the popular Tiled map format, allowing designers easily create levels using the Tiled map editor, and to focus on the game features itself.

Developer Spotlight

   
Master Spy by TurbogunRadmars Team - Ludum Dare & GameJam
radmars intro

Features


  • A fresh and lightweight 2D sprite-based engine
  • Standalone library (no additional dependencies)
  • Modern HTML5 features; WebGL & WebAudio
  • High DPI & auto scaling video modes
  • Tween & Transition effects
  • 2D physics with low cpu requirements:
    • Polygon (SAT) based collision algorithm for accurate detection and response
    • Fast broad-phase collision detection using spatial partitioning
    • Advanced math API for Vector and Matrix
  • A basic set of extensible Object Entities:
    • Object Pooling
    • Basic Particle System
    • Basic animation management
    • Standard spritesheet and Packed Textures (Texture Packer) support
    • Some basic GUI elements
  • Tiled map format integration for easy level design:
    • Orthogonal, Isometric, Hexagonal, and Perspective tilemap support
    • Multiple layers with parallax scrolling
    • Shape-based collision layers (Rectangle, Ellipse, Polygon, and Polyline)
    • JSON and XML formats
  • System and Bitmap fonts
  • A state manager and customizable loader
  • Mouse, Touch, Pointer, and Gamepad device support
  • Device motion, orientation, and accelerometer support
browser icons example

Compatibility


See below about melonJS and compatibility with the various existing browsers.

BrowserVersionStatus
Chrome 12+
Safari 5.0+
Firefox 4+
Opera 11.00+
IE 9+
CocoonJS 2.0+
Chrome for Mobile ?
iOS Safari 6+

Third Party Tools Integration


melonJS provides native integration and support for the following 3rd party tools :