2D engines for JavaScript

28,350

Solution 1

There isn't one right now and I would go on to say that there may never be one in the same way that there is jQuery, for the simple fact that most (commercial) games are going to want to be mercilessly performant, which means using as little extra cruft as possible, and many of these libraries add unnecessary things or performance hits where it may not be desired.

That is not to say they won't be used at all. All of the above libraries are probably good for a great deal of small(er) games.

But I imagine on large projects many studios will find themselves starting with a library until they hit a performance wall, and then writing all the components they used in the library themselves in order to keep only the thin bits that they need.

If there is one that becomes popular it will almost certainly be be modular like MooTools (the second most popular JavaScript library), where it tries to be compact and lets you select only the components you want to use. I imagine you'll find a lot of games in the future that have a very small engine just for handling sound or just for handling images or a 2D isomorphic board, instead of games that have a (large) library that attempts to handle every possible kind of 2D game.

Anyway, if you simply want to find the most popular JavaScript engine then your best bet over the coming months is to use Google (page rank) to determine most popular. Searching for "2D game engines JavaScript/Canvas" will give you a pretty good idea of which is the most linked-to (popular) library at any given time.

(After all, try searching Google for "JavaScript library". You can guess the first result I bet!)

Solution 2

I found this question while searching for an engine of my own. I just want to add this site here because it offers a good overview over a lot of HTML5 game engines:

http://html5gameengine.com/

There are also some nice filters like licenses/costs, release date and user rating.

(PS: I'm not related to this site in any way)

Solution 3

I agree with the others. There just isn't a standard, and there might not be for a while. Yet, I'm just starting out myself - and really digging the ThreeJS framework:

Sure, it's a WebGL 3D framework - but I suspect you can strip out the 3D elements to make it 2D. At least that's my hope as I dig into this world of WebGL - which could end up being the standard moving forward?*

What helps is relying on Chrome Canary for development! :) https://tools.google.com/dlpage/chromesxs

If you're going this route - don't forget to set about:flags in Chrome, to enable "Override software rendering list" flag.

Share:
28,350
Daniel Sloof
Author by

Daniel Sloof

Located in the Netherlands. Business owner and developer (mostly Magento) but interested in all aspects of development. I work for Rubic!

Updated on January 05, 2021

Comments

  • Daniel Sloof
    Daniel Sloof over 3 years

    I'm attempting to build a tile-based game in JavaScript, using HTML5 canvas. There are many engines to choose from, such as

    ... and the list goes on and on.

    However, there does not seem to be one de facto standard among all these different implementations. Essentially I am looking for the jQuery of JavaScript game engines. One that is backed by a (larger) community, has excellent documentation and is actively maintained. Most of these just seem like one-man projects to me.

    What is the de facto standard for 2D game engines in JavaScript?

    Additionally, I would be very interested in experiences with actual implementations (other than demo Pong and Pac-Man games).