Develop looks at the platform with ambitions to challenge Adobe's ubiquitous Flash web player

HTML5: A blessing or a curse?

Initially heralded as the future of browser gaming and the next step beyond the monopolised world of Flash, HTML5 has since faced criticism for being tough to code with and possessing a string of broken features.

The coding platform, the fifth iteration of the HTML standard, was supposed to be a one stop shop for developers looking to create and distribute their game to a multitude of platforms and browsers, but things haven’t been plain sailing.

Not just including the new HTML mark-up language, but also incorporating other features and APIs such as CSS3, SVG and JavaScript, the platform was supposed to allow for the easy insertion of features for the modern browser such as video and audio, and provide them without the need for users to install numerous plug-ins.

And whilst this has worked to a certain degree, and a number of companies such as Microsoft, Apple, Google and Mozilla under the W3C have collaborated to bring together a single open standard, the problems it possesses cannot be ignored.

Breaking up

Perhaps the biggest issue currently plaguing HTML5 is its audio implementation, which many developers claim is broken. Chris Herbert, technical lead of Remode Studios, says that audio is considerably behind the rest of the platform’s features, with problems such as lag and file support, although he believes there could be vast improvements in this area in the future.

“There are clearly areas of HTML5 that need some work, audio being an area that’s lagging behind quite dramatically, particularly in mobile browsers,” he says.

“The problems mainly relate to how sound data is swapped out of sound channels, many browsers are experiencing a lag, or in some cases jumps or pops.

"Also, the support for audio file formats is inconsistent, with some browsers favouring the ogg vorbis format whilst others – such as Safari – favour the MP3 format.

“Issues such as these highlight that this is a technology in its infancy, but given its potential as a fully featured platform in its own right, I believe that we will see HTML5 find maturity much quicker than previous incarnations of HTML.”

Sandy Duncan, CEO of YoYo Games, responsible for 2D-focused engine Game Maker, agrees that audio is broken and says that this is an issue that is being worked on, but due to the cross-platform nature of HTML5, will take time to be approved.

“As to audio being broken, yes it is a little,” he says.

“The browser guys know this, and are working hard to fix it, but with much of the core browser being used on many platforms, it has to be verified and checked a lot to make sure it won’t just kill something and that makes some changes a little slow to come through.

“The new WebAudio API will help though; it gives a very flexible audio system without the old baggage the audio tag brings.”

But the need to fix the issue is presenting its own problems, says Steven Goodwin, creator of cross-platform tool SGX Engine. He believes it has the potential to create a divergence in solutions, which seems against the nature of why HTML5 was developed in the first place.

“Both Google and Mozilla are building solutions to the problem, but in different ways,” says Goodwin.

“This is creating the same problems in divergence that plagued the web in years gone by. While middleware is a good interim solution – SGX itself uses the jPlayer library, which falls back to Flash – the real solution is for the W3C to work with app and browser developers to create a good standard that everyone can follow.”

A debugging nightmare

Whilst the issue of audio problems appears unanimously negative, issues with its programming are up for debate. Despite many devs being uncomfortable with coding in JavaScript, others have found workarounds and suitable tools to help with overcoming problems such as cross-browser compatibility and JavaScript debugging.

Goodwin says that developing in this language can be a “debugging nightmare”, as errors are allowed to sail through to run-time instead of being caught at the compile period, making creating games at times a torrid process.

But he believes that JavaScript has an unfortunate reputation because of these issues.

“If you write with the same diligence you would if it were C++, you will stand a better chance of keeping your sanity,” he explains.

“JavaScript, as a language, is very capable, it’s just unfortunate that it has a bad reputation because it was always used to interact with different – incompatible – browsers.”

Herbert goes as far as to defend HTML5 in this area, and says he does not feel it is difficult to program with, but on the contrary, JavaScript has many ideal features suited for creating browser games and that developers just need to become more accustomed to coding with the language.

“I certainly wouldn’t agree that HTML5 is difficult to program with, it’s an ideal environment for the sort of rapid prototyping,” says Herbert.

“OOP in JavaScript can be a little weird for developers used to C# or Java, not least because the syntax at first glance would be very forgiving but there’s no apparent and solid definition for what a ‘class’ is in JavaScript.

"Although any OOP design pattern will translate into JavaScript, it does take a little getting used to.”

Whilst these technical issues can be overcome in the near future as a plethora of companies search for the best standard solutions, another of the biggest obstacles HTML5 faces in the near future is the size of its userbase.

Attracting users

Whilst it is undoubtedly open to hundreds of millions of people – reportedly more than 800 million – its biggest rival Flash has a userbase of more than two billion, and it is supported by most current browsers, compared to just 40 per cent that support HTML5.

With Flash being so readily available and used by most potential customers, it has been hard for HTML5 to break through, particularly on the back of its early teething problems, and the fact that it is still under development.

“HTML5 use has definitely been picking up, with browsers rapidly adopting HTML5 specifications, but we’re waiting for consumers to update their browsers,” says Peter Driessen, CEO of social gaming giant Spil Games.

“HTML5 isn’t ideal for out-of-date browsers, which a sizeable chunk of the population still uses on its computers and mobile devices.”

But Duncan believes this won’t be a problem for the platform for long, with many new browsers ditching Flash altogether and integrating HTML5, whilst Apple and Microsoft have forgone the use of Flash on iOS and Windows 8 altogether.

“With the auto-update features of Chrome, Firefox, Opera and now Internet Explorer, I think users will be dragged kicking and screaming into the new world whether they like it or not,” he asserts.

“And to be honest, it’s for the best – old browsers are slow, sometimes bug ridden, and full of security holes, so an auto update is for the best.

"This makes it really attractive to developers though, as they can be assured that ‘most’ users who care about running things like games will probably be up-to-date, and if not, be willing to go and download a new browser to get there.”

Scirra’s web developer Tom Gullen agrees, saying that as long as progress is made, users will eventually adopt the platform anyway, so devs shouldn’t be afraid to use it.

“Some are but they shouldn’t be. It’s obvious to us that HTML5 is the next big growth area on the web,” states Gullen.

“As long as HTML5 keeps progressing as it is and browsers keep working to support it as well as possible, the userbase will keep on growing and eventually surpass Flash.”

Ibon Tolosana, CTO of CocoonJS creator Ludei, says that HTML5’s potential to dominate as the web development standard is a key benefit of adopting it now, rather than get caught out and left behind once it becomes the norm.

He also says that despite the criticisms aimed at JavaScript, it has become one of the most common development languages in use.

Untapped potential

“Being prepared for the imminent change is an important reason for developers to start adopting the technology gradually in their projects,” he says.

“Recently, JavaScript has become the most popular development language on GitHub, surpassing Python and Java. HTML5 can be a great option to develop some projects in and developers should not overlook it.

“The first step is to understand the features and results that HTML5 has to offer and then decide which technology is the best option.

"In terms of user base, we believe that HTML5 adoption is inevitable and will be only a matter of time when its userbase will be as big as where Flash is now.”

As well as its inevitable adoption by the masses, whether welcomed or forced upon them, there are still many benefits from using HTML5 that are often looked over in the face of its more serious problems.

Driessen believes that not having to take on as much work developing for various different platforms means that the cost effectiveness of using it outweights its issues.

“Browser-based gaming, and thus HTML5, saves developers time and money which they otherwise lose when having to modify games for different mobile platforms,” he says.

“Thanks to HTML5’s open standard, devs only have to develop a game once, and it can be easily deployed on all devices with browsers supporting HTML5 such as PCs, iPads, iPhones and Google phones.”

An industry standard

He adds that as well as making games available on multiple devices, it allows users to instantly play their games, rather than have to deal with installation hassles and the delays in having to download them from app stores.

Remode Studio’s creative director, Martin Darby, agrees that the ability to run a game in a browser without plug-ins is a huge boon for HTML5, and even allows developers to bypass Apple’s own store and its approval processes.

“Clearly Apple’s reluctance to support Flash and now Microsoft following suit with its Windows 8 devices is giving HTML5 a lot of momentum at the moment.

"Because it falls under the remit of the WC3 it will be a lot more difficult for major platform providers to drop support for it,” says Darby.

“The upshot of this is that anything running on the open web effectively allows you to side-step the app store and all of Apple’s terms and approval processes that go with it.”

Goodwin believes that another of HTML5’s benefits is being able to make use of a wider range of tools, such as his own SGX Engine, than was available under Flash, helping make development easier. This, he says, is something that will only continue to improve.

“The main benefit is being able to use a wider range of development tools. And they’re usually free,” he says.

“Both Chrome and Firefox have good debuggers, and provide the most important functionality of IDEs such as Flex builder. Consequently, the turnaround time from implementing a change, to testing it live, are very short making it ideal for rapid prototypes, and game balancing.

“Also, because JavaScript has been around for ages, there’s a large talent pool available who are used to the problems – and solutions – of the language, and can handle the client-server communications necessary in service-oriented games.”

And, despite the company’s obvious allegiance to the use of Flash, at least in part, Adobe has also begun to join the HTML5 trend, creating tools to help developers leverage its capabilities.

Adobe group product manager Deepa Subramaniam says, though, that developers should ultimately choose the platform that is right for them, and that matches their needs.

“HTML capabilities around graphics, audio/video, data management and application-development, will improve in time – but it does take longer for consistent implementation to be reached across popular browsers and platforms,” she says.

“It’s important for developers to analyse the requirements of the content they are aiming to build and choose the appropriate technology based on those needs.”

The future

It seems that despite all of the criticisms HTML5 faces, and its big issues with problematic features such as audio integration, developers are keen to keep on supporting the platform and see it through to the end, in the hope of creating a single standard that can allow their games to be deployed across multiple devices with ease.

Gullen believes that this will happen sooner rather than later, and it could take just a couple of years to become the most popular platform integrated into modern media devices.

“I do believe, however, that in less than five years – maybe only one or two – HTML5 will be the standard for browser games and yes, this will be a good thing,” he states.

“Flash is very old proprietary technology. It’s had its moment and now it’s time to move over. Adobe knows this as well and is shuffling over to HTML5.

"Within five years I expect and hope that just about every modern media device will support HTML5 in some capacity. It’s an exciting technology with an exciting future ahead of it.”

It seems then, whether developers like it or not, HTML5 is here to stay. So they’ll have to adapt, even if that means they are dragged kicking and screaming all the way through until its potential is fully realised.

About MCV Staff

Check Also

The shortlist for the 2024 MCV/DEVELOP Awards!

After carefully considering the many hundreds of nominations, we have a shortlist! Voting on the winners will begin soon, ahead of the awards ceremony on June 20th