Want to read Slashdot from your mobile device? Point it at m.slashdot.org and keep reading!

 



Forgot your password?
typodupeerror
×
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)

    http://fabiensanglard.net/quakeSource/index.php [fabiensanglard.net] and http://fabiensanglard.net/quake2/index.php [fabiensanglard.net] as hinted by the summary.

  • Comment removed (Score:5, Informative)

    by account_deleted ( 4530225 ) on Tuesday February 19, 2013 @01:50PM (#42946505)
    Comment removed based on user account deletion
  • 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.

Solutions are obvious if one only has the optical power to observe them over the horizon. -- K.A. Arsdall

Working...