top | item 3995669

Why HTML5 is the best platform for rapid game development

81 points| austinhallock | 14 years ago |austinhallock.com

54 comments

order
[+] varelse|14 years ago|reply
All IMO of course, but programming HTML 5 Canvas apps today feels like having a late 1980s vintage CPU strapped to an early 2000s GPU. This is a really unbalanced combination IMO.

Given this imbalance, when I was at a recent employer, I suggested that exposing OpenCL or CUDA within the browser could lead to some really cool games and web apps. I was soundly shut down. Right around the same time, WebCL was announced: http://www.khronos.org/webcl/.

But it doesn't seem like it's moving particularly fast, sigh...

[+] nextparadigms|14 years ago|reply
OpenCL is going to become a big thing for games going into 2013 now that all new mobile GPU's will support it. Thew new GPU's will also support OpenGL ES 3.0, so I'm curious what kind of mobile games we'll see within a year or so.
[+] AshleysBrain|14 years ago|reply
Modern browser's HTML5 canvas is hardware-accelerated, so you most likely get a fully utilised late 2000s GPU. And since many games spend 90% of their time in rendering, the slower JS performance isn't a big deal.
[+] dsirijus|14 years ago|reply
As a rapid game producer, I'm calling this bullshit.

Fastest rapid game dev is with Flash, and nothing has come even close to it (just poke around game dev jams).

Now, if you need mobile support, go with HaXe, it has HTML5 target too. As well as native iOS and Android and much more.

[+] jiggy2011|14 years ago|reply
With HTML5 you also have to worry about the cross browser compatibility mess , which doesn't seem to work well as "rapid" development.

Not to mention that I think writing something like a scene graph in JS would make me rage.

[+] austinhallock|14 years ago|reply
In my experience (5 HTML5 games), I haven't had many problems with cross browser compatibility. Chrome, FF, Safari and IE9 and work surprisingly consistently, at least with the methods I'm using... If I were to dig deeper into audio in my games, yeah I'd have to play with it a bit (though there are existing audio shims).
[+] Kiro|14 years ago|reply
Either the browser supports canvas or not. It's not much more mess than that and definitely not as messy as making a normal website cross compatible.
[+] jjcm|14 years ago|reply
Also performance right now simply isn't up to par. I'm writing some apps right now that heavily utilize the canvas element, and I'm having to rewrite a large portion of it at the moment simply because I can't get more than 5 fps on one of the new ipads.
[+] pjmlp|14 years ago|reply
This is exactly why the only place for applications is the desktop with native applications.

The gain in productivity wins hands down against the mess of having JavaScript+HTML+CSS working the same way across browsers and OS.

[+] Dove|14 years ago|reply
I don’t think anyone will argue the fact that the only other platform I would’ve been able to rapidly develop and deploy games like Nick vs Bus and Word Wars would be Flash.

I would argue it. The speed with which you can develop simple games has much more to do with how well you understand the platform itself (its tools, libraries, capabilities) than what the platform is.

I'm not saying platforms and languages don't intrinsically affect your pace. They do. But it also depends a lot on what you're doing. One language lets you write a web server in an hour; another allows fast and robust mathematical analysis. Writing a fun game in 24 hours is such a pliable goal that you could clear it with, say, a graphing calculator, an industrial robot, or a Word macro. To say nothing of languages people actually write games in!

[+] austinhallock|14 years ago|reply
That's a valid point. I updated the wording a bit.
[+] bryceneal|14 years ago|reply
The "game" is bad and and this article is bad.

A lot of the points the author is making in favor of HTML5 are simply not true.

No Compiling - Languages like flash can build while you and work and compile in under 5 seconds. This is also not a compelling reason to choose a platform, and no intelligent person has ever chosen a platform based on how fast it compiles.

Easy Testing - HTML5 is no easier to test than anything else. Perhaps having to connect a device to test would be an exception. Simply not true.

It's not a plugin - This is irrelevant. If we're talking about browsers, flash has more penetration than HTML5 does right now. So which is worse -- a plugin that 99% of PC users already have, or an executable installer that needs to be run in order to update or change to a browser that supports canvas?

You can rapidly prototype with many languages. I am not arguing against HTML5 at all. Infact, I believe it is probably the future of casual web games. I am only arguing against this poorly written article. The author actually claims that HTML5 is better because of the "hype" around it. Give me a break.

The only final thing I will say is that javascript is a shitty language to write anything like a big game in. If you know anything about CS fundamentals, then you can't refute this fact.

[+] tomjen3|14 years ago|reply
I have to call bullshit -- he could have made those games in Unity3D and gotten a better environment and better (and more extensive) math libraries.
[+] epaik|14 years ago|reply
While Unity is extremely powerful, the point that it's plugin based for browser accessibility remains.

My biggest draw towards developing games in HTML5 is that it runs natively in (almost) all browsers.

[+] batista|14 years ago|reply
They were not 3D games for starters. So he would have to abuse the "better environment". Second, he specifically mentioned the ease of deployment to all kinds of devices and the ease of collaboration on the development of the same game.
[+] epaik|14 years ago|reply
I love participating in game jams. For those who haven't heard, a game jam is an event where you have a limited number of time (maybe 48 or 72 hours) to develop a game.

One of my favorites to participate in is Ludum Dare. This past LD, I used HTML5 to develop my game. It was the first major project in which I used Javascript and Canvas, and the code could've been better, but I managed to quickly develop and prototype a game I'm proud of within 72 hours[1].

The biggest issue with HTML5 isn't the speed of development, but rather the fact that it's not a mature technology yet. I still haven't ironed out some issues with sound and resource loading that works consistently between Chrome, Firefox, and Safari.

[1] http://ekun.nukenine.com/two/game.html

[+] tagawa|14 years ago|reply
A couple of issues:

1. "assuming you’re with the rest of us in the 21st century" - that's pretty insulting to the millions who can't afford a smartphone.

2. "it’ll run from your phone’s browser" - but only if it's WebKit.

[+] austinhallock|14 years ago|reply
1. Changed that blurb 2. I don't have an Android/WP7 phone to test it on, does it not work from yours?
[+] pacomerh|14 years ago|reply
Wether this is the fastest way to make games or not, the demand for HTML5 game engineering is gaining traction in several ways. HTML5 framework makers are promising one time develop and multiple platform deploy, which in theory sounds very nice. And 'optimist' game developers are really having fun using their already mastered web standards skills to create one page games. Why is there so much interest?, you have to wonder. I have these assumptions.
[+] Skoofoo|14 years ago|reply
As a platform for game development, there is much better out there than HTML5.

With HTML5 you have to deal with many serious faults that do not exist when working with many other platforms. HTML5 canvas doesn't feature the ability to turn off anti-aliasing, HTML5 audio has only one channel per instance, has latency issues and is inconsistently implemented, JavaScript has many various faults, performance leaves something to be desired, you cannot do things that are common in most games like going fullscreen or grabbing the mouse, and overall it just feels like you have to wrestle with your web browser to write a game on top of it.

It is convenient to simply link a game to someone and let them play without manually downloading it, but is it really worth hacking around all these issues? Like the web browser was designed decades ago to share formatted text and images, we should design a modern, open browser that makes sense for video games. Perhaps something that combines the best qualities of web gaming and Steam, and distributes data through decentralized P2P?

[+] stesch|14 years ago|reply
Funny. It's an empty page with NoScript.
[+] nacs|14 years ago|reply
Also funny -- Diablo 3 doesn't work when I disable my graphics card. /s
[+] dc-tech-fan|14 years ago|reply
Doodle or Die is all HTML5.

Doodles are stored as JSONP: http://doodles.s3.amazonaws.com/d2/5iSFn-ME/8qp73zuBe.js

This json renders in canvas as the page loads like these amazing drawings: http://doodleordie.com/profile/underwearhero

We want to make a native mobile app because we've heard that HTML5 is slow enough to frustrating. I tried a Lua-based framework and it was fun to use but the resulting drawing too was too slow to be usable because every line had to be created as a new object, instead of Canvas-like pixel manipulation.

[+] novalis|14 years ago|reply
The poster says on the Flash topic: "but I can see HTML5 being favored over something that is completely beyond their control." ...and further down, on security as a flaw: "you can make your game secure, you just need a backend that can be done fairly easily with node.js."

This strikes as an incredible double standard for appreciation that permeates the article top to bottom. I do understand why the poster is so enthusiastic for developing games rapidly in HTML and went about it cutting some corners when having to compromise. But enthusiasm is just that, doesn't make said games any good by default or the plat to magicly be mature to the point it should.

[+] freditup|14 years ago|reply
I feel that the error the compiler will find will more than make up for the very few seconds it would take to compile a game like Nick vs. Bus. I also don't think the single corporation and plugin points makes a direct difference to game development (I would argue it does if you had to buy expensive tools just to develop for Flash or HTML5.)

My personal opinion is still that Flash is a better platform for games, at least right at the moment. I have nothing against HTML5, although I'm not a big fan of JS as a programming language. Undoubtedly ads and such should move to HTML5/JS. I'm still not convinced about it for games yet.

[+] bazookaBen|14 years ago|reply
write about HTML5 game distribution, i'd love to hear input on this.
[+] duwease|14 years ago|reply
Yes, the first thing I thought after "ooh, neat" was "Are there any portal communities for HTML5 even close to those for Flash?"
[+] basicallydan|14 years ago|reply
Obviously, it's especially pretty awesome for multiplayer game development because you don't have to worry too much about figuring out what method of communication to use, firewalls, etc.
[+] sil3ntmac|14 years ago|reply
Yes and no. Websockets is awesome, but no UDP support yet (although chrome nightlies have added this as an experimental feature!). Once UDP comes, we can do p2p and eliminate the server round-trip (as well as the whole TCP ACK bottleneck), vastly speeding up realtime games... but then we have to deal with firewalls :D So its up to the dev to pick his battles, although I'm sure there will be libraries to vastly speed this thing up.
[+] factorial|14 years ago|reply
"Honestly, HTML5 games get more attention just for being HTML5 – deserved or not."

...that's one of his arguments why HTML5 is the "best platform". I wish he would have gone more into detail how he defines "best" as his understanding of that adjective doesn't seem to take into account that more mature platforms have some benefits too. For instance, maturity.

[+] austinhallock|14 years ago|reply
It's definitely a shallow argument, but still a pro for HTML5 nonetheless. If I can make a game that's more likely to be played simply because of the tool I use, it's more lucrative to me.

I listed various other arguments for why I feel it's the "best" out there right now. I think the strongest arguments however are the two games in < 24 hours each.