Trigger Rally – online edition

Trigger Rally is a fast-paced open source racing game for Linux, maintained by a small but dedicated team of developers. The game itself adheres to the same open principals as the operating system it was originally built for, using creatively licensed art, audio and 3D assets. And it’s now available to play online through this WebGL port by jareiko.

WebGL and Three.JS power the graphics. A 1024×1024 sky box surrounds the scene and the level and car model data is pulled in using the Three.JS json format. Level maps are interesting, using a combination of a height map to generate the level geometry, a color map combined with an external texture to paint the land, and foliage and checkpoint maps for details. This means you can create your own rally map using nothing more than a paint package. Perhaps one could even be built into the online version, then you could draw your own map and race on it!

The car engine noises are generated using the Web Audio API. A standard engine loop is pitch-shifted in real-time during play to tie in with the acceleration of the car. It’s a simple process but works remarkably well.

Driving physics routines have been converted to JavaScript from the original C code but the author has stated a desire to port it over to the bullet / ammo.js physics engine. It does feel a little like driving on glass at the moment, but for a first conversion and with such an easy way to create content it has a promising future ahead.

About Richard Davey

Richard (@photonstorm) runs Photon Storm full-time, where he works on the Phaser HTML5 Game Framework. Gaming and the demo scene have been a passion of his since the 8-bit era, and he's extremely excited at seeing both of these charging into modern web technology. According to his wife he also collects an obsessive amount of retro gaming magazines, but he would claim they're just for research. Find him on Google+

CreativeJS

CreativeJS.com is the go-to place to find exciting JavaScript demos, projects, games, and well, anything else that we think is awesome. We've got a whole team here to bring you the best of what's out there. Find out all about us.

Suggest a site

Do have a project or site you think we should feature? Whether it's yours or just something you've seen that you love, go on and tell us about it!