Physics in Mass Market Games

By Calen Henry and Jacob Karsemeyer [05.06.08]

 You're a special agent behind enemy lines. Tucked into a dark bunker, your heart races as you hear the rapidly approaching footsteps of a hostile guard. You cock your pistol, careful to not alert the guard. As he comes around the corner you hold your breath in anticipation. You raise the gun, lining up the sights with his head, but when you pull the trigger, he doesn't react as you'd expect. Instead of falling backward, he awkwardly collapses towards you, his arm passing through a nearby wall. You're immediately ripped from the otherwise immersive experience and remember you were just playing a computer game.

Physics are an important factor in creating an immersive experience in video games. All the most memorable games have found ways of overcoming the technological constraints of their time to create experiences that kept players coming back. When physics are done wrong, it can be disastrous. Bargain bins are littered with games that invested more in movie licenses or flashy graphics than they did into tweaking the physics to make the gameplay enjoyable. But when done right, the results are powerful and memorable.

To understand the current climate of game physics, one must first understand a brief history of pivotal games physics technologies and how they have influenced other game developers, as well as current technologies that are still in the process of being introduced.

The Golden Era: 1962-1981
Even before the advanced 3D graphics of current generation video games, physics played an important role in the game experience. One of the earliest examples of successful game physics is in Spacewar, released in 1962. In Spacewar, players control spaceships that fire bullets and missiles at one another while avoiding being shot or colliding with a star. The physics in that game calculates a gravitational pull that arcs the trajectory of bullet fire, and pulls ships toward them. This gives the game a unique feel that even later more technologically advanced games like Asteroids can't reproduce.

A decade later Pong brought games to mainstream audiences. While Pong had primitive gameplay -- two paddles knocking a ball back and forth -- it's based on a simple physics calculation that determines where on the paddle the ball will hit and bounces it back at the appropriate angle. Atari knew it was on to something good and used the same game mechanic in a single-player version, Breakout. Instead of trying to beat an opponent, the player tries to destroy stationary bricks.

Meanwhile, while the bulk of game makers were designing games set in abstract and alien worlds, a Japanese company was working on a video game with a more human protagonist.  Donkey Kong, the first "jumping" game, or platformer, was released in 1981 (Maria, 193) and garnered a great deal of public attention. Instead of piloting a ship like in Spacewar, or a floating paddle like in Pong, Donkey Kong players control a carpenter named Jumpman.

Physics were still very primitive when the game was released. Jumpman climbed ladders and hopped over barrels, but these actions were applied in an effective and inviting way that kept players coming back. To this day, Donkey Kong has one of the most competitive player communities, as noted in the film The King of Kong: A Fistful of Quarters. Nintendo capitalized on the popularity of the jumping technique, releasing a series of subsequent games that used the same mechanic.

Donkey Kong was a huge success. Nintendo's next step was to invest the money it had earned from its successful arcade machines to create a video game console intended the home -- the Nintendo Entertainment System (NES) in North America and the Family Computer (Famicom) in Japan. Super Mario Bros., which shipped with the system, featured another jumping character, only now he was named Mario and was a plumber instead of a carpenter.

Friction and momentum were added to the physics in Super Mario Bros., which gave the game a more realistic feel. If Mario is running quickly before he jumps, he travels farther than if he was walking before the jump. And he slowly slides to a halt depending on how fast he was running. Using software to emulate real world physics made the game more intuitive. These basic additions to the jump and dodge mechanic brought platforming to a new level and was used in countless subsequent games. Soon all of Mario's competitors -- Sonic the Hedgehog, the Ninja Turtles -- were slipping and sliding around with realistic momentum. Super Mario Bros. went on to be far more successful than any of the previous Nintendo games and has sold more copies than any other Mario game (gamecubicle.com).

 The 2.5D Years: 1990-1996
While some game designers were just starting to understand how to manipulate software to allow for enjoyable physics in 2D games, a different group was working on something entirely different: ways to display 3D images. "2.5D" is a term used for some of the early attempts at creating the illusion of 3D.

When game developers made the jump from 2D to 2.5D, they compromised a lot of the progress they had made in refining gameplay experiences through physics. The first computer games to attempt to mimic 3D used a process called ray-tracing to draw lines between the floor and roof based on the inputted coordinates that would then be skewed to simulate depth. Games like 3D Monster Maze (shown) used this method to achieve early 3D graphics on a PC, but none of them achieved mainstream success.

Video games consoles of the early to mid 1990s didn't have enough computing power to perform ray-tracing. To circumvent that problem, Nintendo started development on a few games using a new technology called Mode 7. Mode 7 mapped two dimensional textures into a 3D space by rotating them so that the player moved across them instead of along them. These games were still essentially two dimensional, but width was mapped across depth to give the illusion of three dimensions. When Teenage Mutant Ninja Turtles: Turtles in Time was ported from arcade to the Super Nintendo Entertainment System, an entire level "was changed from a regular side-scrolling view in the arcade to a Mode 7 view" (wikipedia.com) so that the players moved "into" the screen rather than across it.

As 3D games progressed, the rapidly advancing technology of the PC became a more attractive medium for game makers looking to push as  many pixels as possible. Although the first 3D computer games like 3D Monster Maze preceded it by more than a decade, it was Wolfenstein 3D (left) that really brought 3D graphics into the mainstream. Wolfenstein is a first-person shooter -- the player sees through the eyes of the character. While Wolfenstein was the breakthrough game that really propelled the FPS genre, the in-game physics were still primitive. Id Software, who developed Wolfenstein, used a slightly more advanced version of ray tracing called ray casting, which was capable of scaling characters to simulate depth and drawing textures onto objects.

Both ray tracing and ray casting are algorithms used to render 3D scenes on 2D screens. Ray casting is much faster to process. Games like Doom and Duke Nukem, further refined the 2.5D, or pseudo-3D technology to allow more creative control, but it wasn't until id Software revealed Quake that the game-playing community really got a chance to experience a true 3D experience.

The Wonderful World of 3D: 1996-Present
Quake was released in 1996 by id software and was the first widely successful true 3D game (though Descent, a less popular, but still well-known game, had utilized full 3D one year earlier). The characters and levels in Quake were made up of 3D models instead of 2D sprites, which were quite revolutionary for the time and allowed for physics to be effectively applied to true 3D space.

Explosions push objects and players back, players run and jump in a more realistic way, and when directly hit with a rocket, enemies explode into giblets (or "gibs," as the gaming community calls them) of flesh. These new physics not only made gameplay more realistic and immersive, but also created potential for players to experiment in ways that the designers had not expected. Rocket jumping was one tactic that emerged. The player jumps while firing a rocket straight down so that the explosion propels him farther into the air. The game development community began to realize that giving players some simple physics-based mechanics lets them experiment with the game and experience it in ways that had not been possible before. Other PC games like Camageddon (1997) and Die by the Sword (1998) further pushed the available hardware to generate believable physics.

In the 32-bit console era of Sega Saturn and Sony PlayStation, many 2D game developers unsuccessfully attempted to bring their games into 3D. But it was a title that featured everyone's favorite plumber Mario that successfully brought 3D gaming to consoles. In Mario 64 (1996), all the physics that made Mario popular in his beloved 2D franchise were translated into 3D. He jumps, slides, and bounces through three dimensions just as smoothly as he had in two. This game set a high bar for other games trying to make the leap from 2D to 3D.

Nintendo was clearly adept at rendering physics in ways that made its games engaging. The recently released Super Mario Galaxy is a testament to Nintendo's ability to continue pushing the envelope in that regard. Galaxy features globe-shaped levels that have gravitational pull so that Mario can run along the underside of the globe without falling into space. By manipulating this mechanic in every way possible, Nintendo has again given other game developers a lesson in how to use physics to create successful games.

Realism vs. Arcade
Once game developers started to become more comfortable with developing games in 3D and two distinct streams of gameplay emerged: arcade and simulation.

In arcade games, the physics were used less to create realistic situations and more to enhance gameplay. Arcade-style games are often marked by outrageous and spectacular acrobatics executed at the push of a button. Simulation games go the other route, using physics as realistically as possible, leading to unforgiving, but rewarding gameplay experiences. These distinctions are most obvious in sports games.

In racing games, Gran Turismo tends to represent "realism" at its finest. Never before had a game so accurately captured the experience of driving. Each of the game's 150 licensed automobiles feels unique and true to the real world car they emulate. Gran Turismo cars "mimic the physics of their real-life counterparts" (gamecritics.com).

On the other side of the spectrum, games like Cruis'n USA and Burnout Revenge let players smash through other cars as though they were empty garbage bins. These arcade-style games are much faster paced, with cars using nitrous oxide to travel at airplane-like speeds. Large jumps that would destroy any real world car instead give bonus points or nitrous refills. In these games, physics are used to create more stimulating experiences, rather than more realistic ones. The recent Xbox 360 game Burnout Paradise features some of the most technically advanced and fantastical bumper rumpling car crash physics seen in a game. Cars wrap around poles and crumple like an accordion when they collide with a wall. How physics are implemented in a game determine what style of gameplay the final product will have, whether it's a true-to-life simulation or a fantastical experience.

 Dead Stuff
Physics has also been used to manage the behavior of characters when they are killed, though early 3D games used animation-based systems instead. Each character model had a specific way it died, no matter how or where it was killed. Once 3D game hardware advanced enough to allow for more complex physics, location-based damage models started to emerge. Soldier of Fortune, for example, uses the GHOUL system, which calculates where a model was shot so that the model reacts with an appropriate animation. If the character is shot in the leg, it grabs its leg; if the character takes a well-aimed shot to the head, its skull explodes. Later versions of the game broke character models into smaller pieces allowing for an even greater variety of dismemberments and cranial detonations.

Ragdoll physics gave game developers a chance to break away from the static death animations that they had grown accustomed to. With ragdoll physics, once a character dies, its body falls or slumps in a realistic fashion that is unique each time. 2001's Max Payne combined ragdoll physics with Matrix-like slow motion to give players a frame-by-frame view of their enemies' bodies recoiling from bullet fire.

NaturalMotion's Euphoria is a relatively new technology that combines ragdoll physics with character animations to create a realistic gaming experience. Euphoria "is designed to replace canned animation data in a selective and non-disruptive way, and is capable of creating unique game moments during game play" (NaturalMotion).

One problem with ragdoll physics is that once a character has been "rag dolled," it must be reset before the player can control it again. In shooting games when players are dying, this works fine; but in football or skateboarding games, it can take away from the experience. In theory, Euphoria will seamlessly blend physics-based interaction with the environment into animation-based movements so characters can stumble and fall, correct their footing, and then continue walking in a realistic manner. The recently released Grand Theft Auto IV is the first game on the market to use the technology.

Interactivity and Immersive Physical Environments
In the post-3D years, environmental physics have come to the forefront. The previously rapid pace of graphical advancement has slowed down, while advancements in physics has accelerated.

Half-Life 2 can all be considered the end result of the graphics boom, as well as the beginning of the interactivity boom. The game was released in 2004 and featured some of the most realistic physics of its time. It focused on interactivity with physical objects, and many of the puzzles in the game revolved around the manipulation of objects while taking into account real world physics such as gravity, weight, magnetism, and buoyancy. The game even gives the player a "gravity gun," which can be used to lift up, propel, and move around objects to see how they behave. By forcing the player to interact with the games physics to solve puzzles and make progress, Half-Life 2 ensured that everyone who plays it has a chance to experience the new generation of game physics.

Interactive worlds like those in Half-Life 2 are not new. A notable earlier game that advanced interactivity was Jurassic Park: Trespasser (shown), released in 1998. The game was an early attempt on open-world gameplay, but was a dismal failure. Many aspects of the game's engine were too advanced for existing hardware, and aspects of the physics system were too embryonic to function correctly. "There were several notable flaws with Trespasser's solids model as shipped: it ended up only working well when used with roughly cube-shaped boxes with dimensions between 0.5 and 1 meter, it did not model friction well, it was extremely slow, and it was not free of interpenetration even within the size constraints" (Wyckoff).

Furthermore, the game trod too close to realism, eliminating the player's heads-up display and forcing the player to manipulate game objects with a virtual hand -- using a gun's sight or dialing a phone, for example, all of which were too complex to perform easily with the control system. What the game gained in realistic physics it lost in player engagement. It simply wasn't fun.

Trespasser was ahead of its time, but too ambitious. More recent open-world games like the Grand Theft Auto series, Oblivion, and Crysis, have succeeded where it failed due to technological progress.

A recent development in uniform physics models is the ability to have destructible environments. While the concept is not new (it can be traced all the way back to Dig-Dug), current implementations are much more complex. Half-Life 2's advanced object physics do not extend to its environments. Players cannot break through closed doors, and foliage is static and cannot be damaged. These inconsistencies can take away from the immersive experience of playing the game, though in Half-Life 2's case, not enough to warrant any real complaints.

In contrast, levels in Crysis are much more interactive. Crysis can "[d]ynamically physicallize (using previously defined breaking or shattering characteristics) any arbitrary environmental object or shape, in order to destroy buildings, trees, or other objects, and then further interact with the resulting pieces" (CryENGINE2 Features). Structures and foliage can be destroyed. The leaves of large plants react to the player brushing up against them. This creates a much more cohesive world for the player and does not require the player to acknowledge and ignore indestructible objects that really should be destructible.

Game physics are becoming more and more developed. As they do, new forms of interactivity are possible, deepening the player's experience and creating richer environments.

 Physics Engines
To execute realistic physics in 3D games, developers have to devote a portion of the game engine to rendering physical interaction. This is done in one of two ways: by writing a physics engine for the game, or by using an existing middleware physics engine.

Both solutions are common, but using a third-party physics engine is becoming the more popular approach. Crysis uses a proprietary physics engines, but Half-Life 2 uses Havok as a basis. Havok Physics, the leading middleware engine, is currently on its fifth iteration. It uses a dynamic simulation model to simulate "systems of objects that are free to move, usually in three dimensions according to Newton's laws of dynamics, or approximations thereto" (Wikipedia). Because Havok handles all the game physics, it gives game developers more time to work on other things.

Another physics engine provider is Ageia (recently purchased by Nvidia). Ageia's software works with a physics accelerator, a hardware product required to take advantage of its engine. While consumers haven't been very receptive of the additional piece of hardware, some game makers have implemented Ageia physics as an optional feature in their games. LucasArts' upcoming Star Wars: The Force Unleashed uses three separate third-party physics engines: Havok for rigid body physics (objects in the levels), digital molecular modeling (DMM) for material physics, and Euphoria for character interaction with the world. DMM is a system that allows materials in the game (glass, wood, metal) to be assigned realistic properties. This information is fed into Havok and determines how the material will interact with the surrounding environment. DMM is proprietary to LucasArts until September 2008 (lucasarts.com).

As games that use highly dynamic physics models are released, like Force Unleashed, character animation will likely need to change to accommodate the entropy that will occur during play. Increasingly complex physics will call for increasingly complex, character reactions, and the integration of multiple control engines in single games may well become commonplace.

Jacob Karsemeyer and Calen Henry recently completed Half-Life Havoc as a senior thesis project at McMaster University. They both intend to pursue careers in the video game industry, and Jacob is currently working on a conference and web site project called Pushing Play.

Bibliography

Wyckoff, Richard. "Postmortem: DreamWorks Interactive's Trespasser," Gamasutra.com, May 14, 1999. Retrieved February 23, 2008.

"CryENGINE2 Features Document," Crytek. Retrieved February 24, 2008,

"Dynamical Simulation," Wikipedia. Retrieved February 24, 2008.

De Maria, Rusel, and Wilson, Johnny L. (2004). High Score!: The Illustrated History of Electronic Games, second ed. New York: McGraw-Hill/Osborne.

"Euphoria Technical Summary," Natural Motion Ltd. Retrieved February 24, 2008.

"Gran Turismo 3: A-spec," Gamecritics. Retrieved February 24, 2008.

"Havok (software)," Wikipedia. Retrieved February 24, 2008.

"Mario sales data," Gamecubicle. Retrieved February 24, 2008.

"Star Wars: The Force Unleashed -- Tech Info," Lucasarts. Retrieved February 24, 2008.

"Spacewar!" Spacewar. Retrieved February 24, 2008.

 


Return to the web version of this article
Copyright © UBM TechWeb