Yesterday we all had a bit of a song and dance about Doom celebrating its 21st anniversary. That came with photos of its creative process, but today brings something a whole lot more technical: source code. In specific, the source code for Doom’s 3DO port.
It also comes coupled with a short story by Rebecca Ann Heineman, the coder who was tasked with bringing Doom to the console. The transition from PC to console was certainly not a smooth one…
The 3DO was a brand new console back at the birth of the FPS, and so Doom was a must-have. The 3DO’s library was mostly made up of PC ports rather than the games that were on other consoles of the day.
The Doom port was built in ten “intense” weeks. In Heineman’s post on github.com, she explains that when provided with the code, she was mislead about its condition. “ I was told that there was a version in existence with new levels, weapons and features and it only needed “polishing” and optimization to hit the market,” she explains. “After numerous requests for this version, I found out that there was no such thing and that Art Data Interactive was under the false impression that all anyone needed to do to port a game from one platform to another was just to compile the code and adding weapons was as simple as dropping in the art.“
3DO were begging for the game to be released for Christmas 1995, and Heneman finally started work on it in August ‘95. It was going to be a tough couple of months to get it ready for mid-October. Shortcuts would have to be made.
“I had no time to port the music driver, so I had a band that Art Data hired to redo the music so all I needed to do is call a streaming audio function to play the music. This turned out to be an excellent call because while the graphics were lackluster, the music got rave reviews.”
“The vertical walls were drawn with strips using the cell engine. However, the cell engine can’t handle 3D perspective so the floors and ceilings were drawn with software rendering. I simply ran out of time to translate the code to use the cell engine because the implementation I had caused texture tearing.”
Elsewhere the 3DO operating system leaked memory everywhere, the string.h ANSI C library provided by 3DO was full of bugs and had to be entirely re-written, and separate apps for just loading the logo splash screens had to be created.
Heineman has uploaded the entire archive of the port to github. “I hope that everyone who looks at this code, learns something from it, and I’d be happy to answer questions about the hell I went through to make this game. I only wished I had more time to actually polish this back in 1995 so instead of being the worst port of DOOM, it would have been the best one,” she says.