Wolfenstein 3D

The Evolution of Id

The Id Domain



By writing in ANSI C on NeXTStep, Id Software is able to develop and test in a true programmer's environment. Then, using a network, developers are able to send the code to a test PC running DOS and recompile what they are working on to run the game on its natural environment.

In an era of where it often takes 20MB to put in all the advertised features, they did it in less than four.At a time where soundcard compatibility was a big problem, they added on Disney Sound Source as an afterthought for demonstrations. As many larger game companies are coming to terms with cross-platform development, to them it comes naturally.They write games that would take larger companies 30 people or more, and the whole company comprises seven people. They are the programmers at Id Software, and what they are doing could change the PC game industry forever.It was actually Id's previous game,, that earned its accolades. The premise ofwas straight out of a B-movie, in which players battle their way out of a Nazi castle. What madestand out was its brilliant use of bitmapped images, digitized sounds, and blazing speed to give the illusion of a three-dimensional world.Id made use of a technique known as texture mapping that, combined with a raycasting engine written in assembly language, allowed the three-dimensional graphics to be playable on the lowest common denominator machine, at the time a 286.Perhaps, the most amazing aspect ofhad to do with its distribution. It was shareware. Using a time-honored shareware technique, the first 10 levels ofwere free. It was the additional levels that were sold directly through the distributor, a shareware game company called Apogee.This allowed people to copy the first part of the game, which was public domain, and see how well the game performed on their machines before they bought the whole game. The free teaser file spread like a virus until it was all over the world, with over 20 percent of the orders for the complete version coming in from overseas.Here is where Id has potentially made its biggest impact on the PC game industry. By releasing a state-of-the-art game through shareware, it was able to destroy the old shareware game sales record, set by Id's ownseries, by over five times. By totaling sales of over 100,000 units by the end of 1993, Id proved that professional-quality games could be successfully marketed via shareware.To truly compare shareware to traditional distribution, six months after the release of, Id released a revamped version ofcalled. As of late 1993,andhad sold 100,000 copies apiece andsales were still going strong, butsales were slipping as it was being forced off of retail shelves by newer games.However, it's not the sales total that makes this distribution revolutionary, but the profit margin. For example, for every game of, Id would get about $8.00, half the total return split with the retail distributor FormGen. In the case of a Nintendo cartridge of, the return would only be about $2.00.But, by using a shareware distribution system, Id was able to recoup the total price of the game minus the actual cost or materials and having an operator to take orders. In the case of, the cost of materials was less than $5.00, and the complete game cost $50. Although they did split the profit with Apogee, this gave them a profit margin any software company would envy.Id Software has come a long way from its humble roots in Shreveport, La. It was at a company that made monthly game disks called Softdisk where the majority of the Id development team met.John Romero, one of Id's founders, was forwarded some fan letters that were sent in and tacked them up on the wall in his office. He had never given them a second thought until one day, when he was reading an article in a game magazine about a shareware game called, he noticed a familiar address.It turned out that Scott Miller, president of Apogee, saw one of the games Romero and his colleagues had created for Softdisk and wanted it for his shareware distribution company.Miller, knowing that all mail to Softdisk would be opened at the front desk, wrote phony fan mail to the programmers under a variety of names and always ended the letters with "please write me at." When John Romero saw the same address on all the fan mail, he realized he didn't have as many fans as he thought. But the one real fan he did have would have a profound impact on his life.Miller knew talent when he saw it, and he wanted what was going to be the future core of the Id development team to work for him. Miller gave Romero and his team a $2,000 check, and they gave him a paragraph containing a game idea that would become the first of thetrilogy.At this point, John Romero, John Carmack, and Adrian Carmack quit their jobs at Softdisk and formed Id Software with Apogee acting as its distributor. After a brief time in Madison, Wis., the Id team moved to its current headquarters in Mesquite, Texas.It is in this corner of suburban Dallas that Id Software has really come into its own. Joining the founding members of lead programmer John Carmack, project leader John Romero, and graphic artist Adrian Carmack, were fellow Soft-disk alums chief operations officer Jay Wilbur, creative director Tom Hall, and printed graphic artist Kevin Cloud.They formed the primary development team forand, and, on completion of those two projects, reaped the rewards.Id's main working environment is a series of PCs networked together, some of which run DOS. However, when it comes to programming, NeXTStep is the team's weapon of choice. John Carmack has never regretted trudging through the snow in Madison to buy a NeXT cube. The level editor that Romero made fortook five human-months to make, but would have taken much longer on any other operating system.

The Super Nintendo Entertainment System (SNES) version of Wolfenstein was developed mostly on the NeXT machine, using an Apple IIGS to compile and retarget the ANSI C code. For future SNES development, Id had planned to retarget the Free Software Foundation Assembler and GNU C compiler to generate 65816 code on the NeXT machine, using a ROM emulator card to upload the code compiled in NeXTStep 486 directly to the Nintendo SNES.



Figure 1 shows DoomED, a good example of what Id can do in NeXTStep. It has the functionality of a simple CAD program and allows level designers to concentrate on level design instead of programming.



From DoomED, the level designer can place monsters and objects (the different colored blocks on the screen), but, more importantly, can manipulate the walls, ceilings, and floors of the game environment. The editor allows bitmap combination from a group created by the graphic artists, so the level editor can improvise without having to draw new bitmaps.



Although it has often been theorized that Id uses a lot of assembly language in its development, the main language used is ANSI C. "Assembly language is almost dead," declares Carmack. "Doom has only two assembler routines: one to vertically stretch a column and the other to horizontally texture-map a row. Everything else is in C."



If all of Doom was written in assembler and the programmer could manage the overhead correctly, Carmack theorizes it would only make the game 15 percent faster. And, although the main raycasting trace in Wolfenstein was written in assembly language, Carmack says he could write Wolfenstein faster in C because of today's better algorithm technology.



Writing in ANSI C eases the strain of porting to other operating systems and recompiling the code on DOS, and NeXTStep helps clean out bugs during the development process. Carmack feels he could get Doom up and running in a window on a Macintosh over a weekend, but Id won't write the port itself.



Id is willing to work with advocates of various operating systems, and talk of Macintosh, OS/2, and UNIX versions of Doom were discussed as possibilities.



The Core of Id



The two people at the core of the Id development team are the biggest fans of Id games and their harshest critics. Lead programmer John Carmack is clearly the main reason behind the technical superiority of Id's games.



Talking to him about the games he's worked on is almost anti-climactic because he always emphasizes how much better he could make them today. When the contractor Id hired to do the network drivers for Doom didn't come through, Carmack matter-of-factly wrote a network driver and had it up and running the next day.



In contrast to Carmack's eternal pessimism regarding his past creations, project specialist John Romero is the biggest fan of Id's games that you could ever hope to meet.



His enthusiasm is infectious as he plays the latest beta making his own sound effects with his mouth to compensate for the game sound effects that haven't been added in yet. It is this mix of diehard programmer who plays games and diehard gamer who programs that ultimately makes Id's games as good as they are.



True to form, John Carmack was already displeased with Wolfenstein by the time it was released to the public. His game engine had been completed in the first month of the six-month development cycle and, by the time the first copy of Wolfenstein was buzzing across the modems of America, he knew he could do better.



While the rest of the Id development team was hard at work completing Wolfenstein, Carmack was writing the game engine that would later be licensed to a company called Raven for the game that was to become Shadowcaster.



This game engine featured more than a one-point perspective and allowed objects to be taller than the player. It was around advances made in the Raven engine that the new game (tentatively titled "Green and Pissed") was to be built. But in the making of what was to become Doom, Id Software severed its relationships with two of the parties that had been around since its beginning.



In the initial development of Doom, a determination was made as to what direction Id's games should take. This decision resulted in founding member Tom Hall leaving Id Software. Carmack and Romero felt that Hall's creativity was coming into conflict with gameplay.



As creative director, Hall was insisting on continuity in the storyline and trying to give the game a plot. As Romero would later say, "You don't need much of a storyline if your game is good."



"The game designer shouldn't be making a world in which the player is just a small part," echoed Carmack. "The player's the boss; it's your duty to entertain him or her." In the midst of this debate and other creative differences, Hall left Id to become project manager at Apogee.



Moving On



After the fallout from Hall's departure, Id crystallized its design ideology. Id's mission is to take cutting-edge technology and turn it into highly playable games. The plot, or lack thereof, in Doom is a good example. It involves the vague idea of starting in a space station and descending into Hell.



Doom, and presumably all of Id's future games, involves just enough of a storyline to set a mood and inject snippets of pop culture, mostly from B-movies. Perhaps it was Carmack who put it best, "We put the player in a dangerous situation and basically let the fight or flight instincts take over."



Another staff split involved Id taking over the distribution for Doom instead of using Apogee. Although the Id staff was pleased initially with Apogee, who gave Id its start in shareware games, the staff felt that Apogee wasn't equipped to handle the onslaught of phone orders that would accompany Doom.



In an ironic twist, after Id had contracted a company called Digital Magnetics to handle the phone orders, Apogee realized that Id was right about its phone order capabilities and ended up hiring Digital Magnetics as well.



Id continues to deal with Apogee with ongoing projects such as Wolfenstein II, which Apogee will develop itself using a slightly souped up Wolfenstein engine. Id still recommends Apogee to potential game programmers as a good place to start.



With the knowledge that Carmack had gained from working on the Raven engine, he started work on Doom. The Raven engine was much more advanced than Wolfenstein. It could render sloping floors, map texture on any side of a cube (in Wolfenstein, a cube had to be the same on all sides), allow different textures for the ceiling, and create walls at angles other than 90 degrees. Unfortunately, the technology used by the Raven engine was as advanced as it would get, so to work on Doom, Carmack had to start from scratch.



Three revisions later, Carmack had a game engine with performance that met his expectations. By breaking the map down into small sectors and reordering them so that the engine was able to make use of the 486's internal cache, the engine was optimized for fast machines.



The final Doom engine has a medium detail mode option that doubles the pixel width horizontally and triples the speed of the game on slower machines. Another important addition to the Doom engine was allowing all objects to have physical characteristics, such as weight, momentum, and even sound.



For example, bullets were actually physical projectiles in the Doom engine as opposed to Wolfenstein, where they were just calculations. Improved AI routines allowed monsters to interact with each other, and light sourcing gave a better sense of depth.



Improved Doom Features



One feature that was built in from the beginning was a multiplayer option. Id added this feature with an eye toward the future. The Doom designers felt that multiplayer games would become increasingly important as the Internet and other forms of commercial networks become part of more homes.



Although Id expects less than 10 percent of players of Doom to make use of the ability, up to four players can join the same game over a Novell IPX network. Id designers felt it was important to start working on multiplayer games now, so they would have the experience when it was more crucial to their development.







Figure 1. DoomED--Using CAD to Build Hell

As soon as the network option was added, however, more complications cropped up. For example, the line-of-sight checks that the monsters' AI programming went through were slowing the game because they had to scan for every player. Another problem with the AI routines was that monsters were targeting some players, but ignoring others. These problems were fixed, but there was a minor problem that had to stay in the game.



The sprites for the individual players were drawn holding a generic gun, which wasn't a big issue when there was only one player. But, with multiple players, an opposing player couldn't tell which of the seven different weapons another player had. To give the players this viewpoint, seven complete sets of sprites would have to be drawn for the character, and the design team felt it wasn't that important.



The graphics for Wolfenstein were drawn completely by Adrian Carmack, but for the Doom graphics, the Id team knew it was going to need help. It enlisted the aid of professional model designer.



The models are placed on a revolving tray where they are secured to the base. There are eight pegs in the tray that represent the eight points of view that are needed by the game engine to render the creatures. Next, the models are animated frame by frame by moving the model and then rotating it to each specific vantage point the engine uses to display it.



The images are digitized by a video camera hooked up to the NeXT machine. When each frame is captured, it is imported over the network into a PC running Electronic Arts' Dpaint, where the photographic source is translated into the resolution of the game. The images are drawn at full brightness, and the game engine varies the contrast for light sourcing.







Gregor Punchatz created a setup that would easily allow the results to be digitized.