I currently support 3 files types: OGG, WAV and MP3. OGG files are generally larger than the other two. Generally speaking I aim to get the game code and assets in to 500k. For all audio I aim to use no more than another 500k such that the game fits in to 1Mb. Downloading a 1Mb game outside of WiFi isn’t a problem in 2012.

For the soundtracks that run through the game I use a very fine composer and old school buddy. You can find his work on SoundCloud. We grew up listening to the awesome music of Rob Hubbard on classics such as Sanxion. I can’t tell you what it means to us to be able to reproduce the arcade thrills and wonderful game music from almost 30 years ago.

For the creation of sound effects I use Audacity. A wonderfully simple tool to use yet extremely versatile and rich with features. You will need a couple of plug-ins to export to different formats but the application will guide you through this.

As a source for my sound effects I fire up MAME and record the audio of a few games. Armed with a WAV file I launch Audacity and start to tweak the sounds until I’m happy that a) it sounds nothing like the original and b) it fits the game.

This is probably copyright hell but just now I’ve not used the work commercially. Most likely by the time I get to use production quality sound effects I will have commissioned them.

Adding sound and music to games is in many respects the final hurdle. Mobile web games have been largely mute this last couple of years. It’s just awesome to be able to offer rich multimedia gaming experiences.

I look forward to presenting my next project, Crossfire, in the next couple of weeks.

Like this:

Many things about developing browser games with Canvas and JavaScript are a real pleasure. Now that I have my game “engine” and framework in place it’s pretty much a case of getting the design right and enjoying the pipeline of art creation.

But some things still niggle me. Not least the poor support for Audio.

If I had to identify just one thing that I’d like to see addressed it’s the support for native Audio across all browsers.

I’m at the point now where I’m playing and testing my games and making stupid beeps and zaps myself to compensate for the fact that my game just doesn’t make them.

In many respects I’m lazy. I’m waiting for the headline that says – “At last ! HTML5 game developers can just use <Audio>and it’ll all work out just nice for them.” I will then go and open up an audio package and an Atari emulator and create some classic effects.
But the reality is more that if I could be bothered to I could “find a way”. I could, with a bit of perseverence hack something together to do the job. I’ve seen plenty of games do it. It’s limited but it works.
But the trouble is I’m just not interested in hacking about for a single channel sound on my phone. Largely because I’d just hand that over to a short, choppy, repeating soundtrack. I don’t want that. I want a full arcade experience which is why I just leave it and continue to make all the sound effects myself as I play.

You can read a bit more about this at the Phobos Lab. It’s quite fun and colourful and well worth a read.