Difference between revisions of "Doom source code"

From 3DGE Wiki
Jump to: navigation, search
(Created page with "{{DoomWiki}}The '''Doom source code''' was released December 23, 1997, initially under a not-for-profit license. Later, permission was granted to re-release the source code un...")
 
m (trimmed as that info is not needed here)
 
Line 8: Line 8:
  
 
The source code can be divided into sections. Files and functions within the source code have one- or two-letter prefixes to denote their subsystem.
 
The source code can be divided into sections. Files and functions within the source code have one- or two-letter prefixes to denote their subsystem.
 
; AM_*
 
:  [[Automap]] code
 
; D_*
 
:  Initialisation/general code
 
; F_*
 
:  "Finale" (end of game) and "[[screen melt]]" code.
 
; G_*
 
:  Main game loop/control
 
; HU_*
 
:  [[Heads-up display]]
 
; I_*
 
:  System-specific code
 
; M_*
 
:  Miscellaneous (includes the menu)
 
; P_*
 
:  Game logic/behaviour
 
; R_*
 
:  [[Doom rendering engine|Rendering engine]]
 
; S_*
 
:  [[Sound]] code
 
; ST_*
 
:  [[Status bar]]
 
; V_*
 
: General graphic rendering
 
; WI_*
 
:  End-of level "intermission" screen
 
; W_*
 
:  [[WAD]] file loading
 
; Z_*
 
:  [[Zone memory|Zone memory allocation system]]
 
 
The following are common prefixes for functions, although they do not denote a particular subsystem, and there are no files with these prefixes:
 
 
; A_*
 
:  Action functions invoked in sprite movement frames (these are the functions used in [[Dehacked]] "code pointers")
 
; PIT_*
 
: Callback functions passed to P_BlockThingsIterator (see p_maputl.c)
 
; T_*
 
: "[[Thinker]]" functions set to be called each clock [[tic]] for some purpose (eg, moving platforms or flickering lights)
 
  
 
A detailed list of files and their purposes can be found in [[Doom source code files]].
 
A detailed list of files and their purposes can be found in [[Doom source code files]].

Latest revision as of 16:10, 8 October 2014

Doomwiki
For more information on this article, visit the Doom source code page on the Doom Wiki.

The Doom source code was released December 23, 1997, initially under a not-for-profit license. Later, permission was granted to re-release the source code under the GNU GPL in October 3, 1999.

Before release, the source code was tidied up by Bernd Kreimeier; the source release includes a changelog of his contributions. Several documentation files are also included. The original plan for the source code release involved a book Kreimeier was to write on the Doom engine; however, due to Doom's decreasing relevance in the gaming community, it was eventually judged not to be a marketable idea, and the project was abandoned. The source code was then released to the public.

Because of legal issues regarding the DMX sound library developed by Paul Radek which was used for Doom, the release was of the source code to the Linux port of Doom. Despite this, within several months, several ports had been made back to DOS. As a result, many source ports exist.

Source code structure

The source code can be divided into sections. Files and functions within the source code have one- or two-letter prefixes to denote their subsystem.

A detailed list of files and their purposes can be found in Doom source code files.