HTML and CSS Reference
In-Depth Information
Chapter 26
Using an HTML5 Game Engine
What's in this chapter?
• Reviewing the history of HTML5 game engines
• Learning about commercial HTML5 engines
• Understanding open-source HTML5 engines Code Downloads for this Chapter
You can find the code downloads for this chapter at
title.cgi?isbn=9781118301326 on the Download Code tab. The code is in the Chapter 26 download and indi-
vidually named according to the names throughout the chapter.
The ease to start with HTML5 game development combined with the growing popularity of HTML5 as a me-
dium to build games quickly has led to a proliferation of game engines, both open-source and commercial. This
chapter examines some of the most popular engines available.
Looking at the History of HTML5 Engines
Although the canvas element has been around in some form since it was introduced by Apple to power OS
X Dashboard components in 2004, it has been only in the past few years that people began to take HTML5
seriously as a platform for game development. There are a myriad of reasons for this, but the performance lim-
itations of JavaScript and the lack of high-performance rendering kept JavaScript from being considered for
serious game development by most sane individuals.
That began to change in 2008. In response to the processing requirements of the increasingly massive
amounts of JavaScript that were beginning to appear in Ajax-heavy applications, such as Google's GMail
JavaScript, performance began to be taken seriously by browser makers.
To help speed up its own applications, Google released the Chrome browser powered by the V8 JavaScript
engine, and Safari and Firefox both launched new JavaScript engines that boosted performance immensely. The
JavaScript arms race was on in full force, and people slowly began to look at JavaScript more and more like a
real language that could be used for larger-scale application development.
Developers have an uncontrollable impulse to program games in whatever medium they work in, and
JavaScript was no different. Simple games in JavaScript have been around since its inception, but in 2008 things
Search WWH ::

Custom Search