Catch up on stories from the past week (and beyond) at the Slashdot story archive


Forgot your password?
Programming Games

Duke Nukem 3D Code Review 128

alancronin writes "Similar to Fabien Sanglard's previous code reviews of other games such as the Quake and Doom line of games comes a review of the code base of Duke Nukem 3D (split out over 4 pages). This will be a very good read for anyone interested in understanding the mechanics of a highly addictive game or anyone that wants to learn more about game design."
This discussion has been archived. No new comments can be posted.

Duke Nukem 3D Code Review

Comments Filter:
  • by crazyjj ( 2598719 ) * on Tuesday February 19, 2013 @12:41PM (#42945707)

    Most methods have "void" parameters and return "void". Everything goes via global variables.
    Methods naming does not use camelCase or NAMESPACE prefix.

    Somewhere, my CS professor just had a simultaneous heart attack/stroke.

  • Re:duke nuken (Score:4, Informative)

    by nedlohs ( 1335013 ) on Tuesday February 19, 2013 @01:37PM (#42946357) [] and [] as hinted by the summary.

  • Re:duke nuken (Score:5, Informative)

    by hairyfeet ( 841228 ) <> on Tuesday February 19, 2013 @01:50PM (#42946505) Journal

    Duke was okay but frankly IMHO it wasn't the best the Build engine had to offer. If you haven't played Blood or Redneck Rampage then you haven't seen what the Build engine could do, huge levels with tons of secrets, plenty of bad guys that would give you a good fight, and while the visuals of course couldn't match Quake you could play the Build games without a graphics card which at the time was NOT cheap.

    so if anybody hasn't tried them GOG has both Blood [] and Redneck Rampage [] and since they are running in DOSBox you can play them on just about any OS. If you really want to see what the Build engine could do those are the ones to play. besides who can't enjoy a game where you shoot a titty gun while drinking beer and listening to Mojo Nixon or go through classic horror sets like the Phantasm mortuary while spouting one liners like a cross between Clint Eastwood and Bruce Campbell?

  • by h4rr4r ( 612664 ) on Tuesday February 19, 2013 @01:53PM (#42946533)

    Which is not what 99% of code does.
    I was speaking generally, and generally globals are a bad idea.

  • Re:duke nuken (Score:5, Informative)

    by Guspaz ( 556486 ) on Tuesday February 19, 2013 @02:12PM (#42946647)

    You couldn't run either Quake or Blood without a graphics card, there wasn't onboard video support back then. Presuming you mean a 3D card, neither Quake nor Blood originally supported 3D cards, and so both ran fine without it.

    Quake did later get a 3d-accelerated version (glquake), but it was by no means required, and was sort of unofficial (Id Software released it, but it was unsupported).

  • Re:duke nuken (Score:5, Informative)

    by Tarlus ( 1000874 ) on Tuesday February 19, 2013 @02:12PM (#42946649)

    Duke 3D was waaay more sophisticated than Wolfenstein. While it did employ similar dated rendering techniques and the need for sprites, it did offer full range of motion along all three dimensions, actual floors and ceilings, interactive environments, the ability to look around using a mouse, and the ability to have passages that could overlap one another. Doom couldn't even do that.

    The Quakes were technologically superior, by far. Three dimensional rendering in the truest sense, greater lighting effects, antialiasing (I think that came about with Quake 2, but correct me if I'm wrong). Network play out the wazoo. Even the audio capabilities were incredible. (I used to love putting different CD's in the drive to change up the soundtrack. Megadeth's "Rust in Peace" goes very well with Quake.)

    But despite all that, I always had more fun with Duke 3D than I did with Quake. It just had a more colorful personality and it had more creative levels. Quake was always so... brown and gray.

  • Re:duke nuken (Score:5, Informative)

    by VGPowerlord ( 621254 ) on Tuesday February 19, 2013 @02:44PM (#42946903)

    Duke Nukem 3D was the first FPS to inject a healthy dose of humor into the game. That is what stands out in my mind over actual gameplay mechanics.

    DN3D also had a wide variety of weapons, some of which were... standard FPS weapons, some which weren't.

    Some of these were pioneered by DN3D, such as:

    • Remote controlled pipe bombs
    • Laser Trip Bombs
    • Freeze gun (which also bounces off walls)
    • Shrink Ray
    • Microwave gun (causes enemies to expand until they explode)
    • Holoduke (or distraction target)
    • Usable item Medkit (as opposed to the ones that are used when you walk over them)

    I should note that I'm focusing mainly on multiplayer things here.

It seems intuitively obvious to me, which means that it might be wrong. -- Chris Torek