oreilly.comSafari Books Online.Conferences.


Free Frags with Cube: The Linux First-Person Shooter

by Howard Wen

The last thing the gaming development community needs is probably another 3-D graphics engine designed for first-person shooters. After all, there are lots of them in the market. Some, such as the original Quake engine, have even been released as open source (although long after they became technically outdated and were no longer of value to license for game development). Cube, however, stands apart because it was targeted at Linux since its inception, and has always been free.

This isn't a project in the experimental stage. Cube is already a fully playable first-person shooter that you can download and play. It even supports Deathmatch, online competitions where human opponents blast each other. It also requires modest hardware: a 500 MHz processor, 64 MB of RAM, and a graphics card with recent and compliant OpenGL drivers. nVIDIA's TNT2 and GeForce cards work very well.

Deathmatching with Cube.

Even better, the source code is released under a license functionally equivalent to the new BSD/MIT/ZLIB licenses. This means that anyone can create an original game using the Cube engine and distribute it. You can make your own game maps, models, and scripts for Cube to build your own action game from the ground up. You can even release it commercially without having to pay licensing fees.

This remarkable piece of software was developed by Wouter van Oortmerssen, a 30-year-old Dutchman. He works as a programmer for a games company in Coburg, Germany and started developing Cube in Fall 2001. Van Oortmerssen didn't intend to frag commercial graphics engines with his open source alternative. Rather, he was motivated by a personal challenge to create "the absolutely simplest engine structure I could get away with, to have some fun programming, and try out some ideas I had without getting bogged down in writing a complex (graphics) renderer."

Because the engine is intended to power first-person shooters, it works best at generating interior locations rather than simulating the outdoors. A future release will allow adjustments to the engine's "camera" perspective. This could be used to create a Tomb Raider-style platform game with a third-person view. This feature is possible, but not yet implemented, in the present release.

Big Game Play in a Small Package

Related Reading

Physics for Game Developers
By David M. Bourg

It's only an 8MB download, but Cube manages to pack in the basics to satisfy most first-person shooter enthusiasts. There are five weapon types: the super shotgun (similar to the one in DOOM II), the rocket launcher (a clone of Quake's), the chain gun (with similarities to the lightning gun in Quake III), the rifle (a counterpart of the railgun in Quake II and III), and the fist (like Quake III's gauntlet). These were chosen with the criteria of being diverse, uncompromising, and fun to use for Deathmatch play.

Cube's various Deathmatch modes provide a frantic play experience akin to Quake or DOOM. (Those seeking slower, more tactical, or "realistic" multi-player game play, like that of Counter-Strike or Rainbow Six, might be disappointed.) Cube has over 20 Deathmatch maps to frag on, and the netcode makes for enjoyable play over the Internet, even at pings over 200. The single-player game play resembles the original DOOM most closely and is designed to force constant movement and fighting.

The engine does not have Deathmatch bots, per se. It does have traditional single-player monsters and enemy characters that can be used in Deathmatch maps. While individual monster characters aren't a big threat to the player, their collective behaviors can pose a threat.

In a Technical Category of Its Own

"It's not easy to directly compare Cube with commercially produced 3-D graphics gaming engines. Cube is technically very different from most other FPS engines. It does some things better than Quake III, yet does some things worse than DOOM II, so it's hard to say where it fits," says van Oortmerssen. On average, he guesses, Cube is similar to the Quake II engine in terms of features and capability.

That said, Cube does outperform most of its competitors in several areas:

  • Its occlusion culling is very precise, fast, and fully dynamic. This results in minimal overdraw, more freedom in level design, and allows for arbitrary modifications to the geometry during game play.

  • The lighting system, though limited in some ways, allows for dynamic soft shadows from many light sources.

  • Cube delivers a multi-player experience smoother than most commercial games.

  • The engine handles maps very efficiently. Load times are measured in fractions of a second. Maps can also be edited in the midst of games.

Dynamic lighting from several sources.

In upcoming versions of Cube, van Oortmerssen plans to include new features such as server browsing, demo recording, role-playing game extensions for the single-player mode, and simple shaders to enhance the graphics.

Pages: 1, 2

Next Pagearrow

Linux Online Certification

Linux/Unix System Administration Certificate Series
Linux/Unix System Administration Certificate Series — This course series targets both beginning and intermediate Linux/Unix users who want to acquire advanced system administration skills, and to back those skills up with a Certificate from the University of Illinois Office of Continuing Education.

Enroll today!

Linux Resources
  • Linux Online
  • The Linux FAQ
  • Linux Kernel Archives
  • Kernel Traffic

  • Sponsored by: