home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the DOOM Gurus / TricksOfTheDoomGurus.iso / editors / edmap / help.txt < prev    next >
Text File  |  1995-03-21  |  231KB  |  4,185 lines

  1. ;HELP.TXT for EdMap v1.40+
  2. ;
  3. ;lines starting with ";" are ignored
  4. ;
  5. ;help entry format:
  6. ;       =========
  7. ;       <keyword>
  8. ;       =========
  9. ;       <text>
  10. ;[+
  11. ;<keywords>]
  12. ;
  13. ;the "===" line must contain nothing but "=", of any length>0
  14. ;
  15. ;<keyword> is the name EdMap will search for to find any entry
  16. ;       from the menus, the function name is the keyword (ex."New Map")
  17. ;
  18. ;<text> is the body of the help message.  there cannot be
  19. ;       and <CR>s in the text unless it is used to start a new
  20. ;       paragraph.
  21. ;control codes: uppercase activates, lower turns off
  22. ;code output
  23. ;  -- ------
  24. ;  $$ $
  25. ;  $P Proportional text
  26. ;  $C Center text
  27. ;  $T Tab
  28. ;  $I Indent
  29. ;  $J Justified
  30. ;  $L Long tab
  31. ;  $U Use x12 font, $u=8
  32. ;  $! End page
  33. ;  $Bxy draw box
  34. ;
  35. ;if there are reference keywords to other help entries,
  36. ;       "+" must mark the end of the text and the start of the
  37. ;       keyword list.  keywords are one per line, no characters other
  38. ; than the actual letters (numbers, etc.: #32..#122?).
  39. ; not case sensitive; lowercase is made uppercase
  40. ;
  41.  
  42. ====
  43. What's New
  44. ====
  45. $CWelcome to EdMap v1.40!
  46.  
  47. This version was based on the theme of TC-support.  TCs (Total Conversions) or themes, replace graphics sounds and even change the game executable to produce an entirely different game.  EdMap v1.x supported DOOM, v1.2 did DOOM II, and v1.3: Heretic.  id released no new games, so I based v1.40 on user-created games.
  48. $!
  49. $t***Improvements new to v1.40
  50. $u$L$IExternal graphics:
  51.     patches (with or without PNAMES)
  52.     textures (TEXTUREx)
  53.     sprites, etc.
  54.     Viewer: faster, of course
  55.         view externals, all sprites.
  56. Much improved on-line help:
  57.     Unofficial DOOM Specs(!)
  58.     Rewritten, control codes.
  59. "Smarter" EDMAPCFG.EXE
  60.     auto-search HDD
  61.     auto-TC install
  62. *Almost every other feature is improved (at least a bit).*
  63. +
  64. Release history
  65. HINTS, TIPS & TRICKS
  66.  
  67. ====
  68. Release history
  69. ====
  70. $t$u$L$I*** new to v1.31
  71. Auto-teleporter creation: use in LD or SE mode 
  72. more extensive, specific & useful error checking
  73. Old(!) builder; using v1.0 again, no SE-merging problem
  74. snap-options from preferences panel
  75. texture replace checks floors, ceilings
  76. many minor improvements
  77. EDMAPCFG bugs fixed
  78. even better at updating TXT->DATs
  79. bug-free??
  80. ..and of course, a faster viewer..
  81.  
  82. *** new to v1.30
  83. HERETIC support!
  84. much better viewer; faster! bugs fixed!
  85. more multiple-selection (INS and DEL) control: 
  86.     sector split, merge, select supporting objects, multiple vertex break, etc.
  87. much better texture aligning; no longer bound to sector, adjusts X and Y offsets.
  88. more checking, checking options panel in preferences.
  89. new vertex info bar; enter LineDef lengths.
  90. cleaner algorithms & main data structure routines (faster??)
  91. better memory management (more free memory??)
  92. all data compiled from included text files; edit TXTs for your own descriptions,
  93.     EdMap will automatically rebuild outdated files.
  94. more colorful map display: colored action LineDefs, 2-S LDs always grey, etc.
  95. pro-mode panels for byte-/bit-wise editing any object. (press space bar)
  96. many improvements
  97.  
  98. *** new to v1.24
  99. Updated builder (see IDBSP.DOC)
  100. new saving algorithm
  101. new data filenames for different DOOMs (???????2.DAT=DOOM-II datafile)
  102. better memory management
  103. better build structure (BUILD.BAT & EDMAPCOM.EXE)
  104. much improved EDMAPCFG.EXE
  105. help keyword-search panel
  106. negative steps (for auto-stairs)
  107. new sector selection algorithm (using mouse)
  108. new vertex info bar: editable linedef lengths
  109. many other improvements.
  110. bugs fixed from v1.22 & v1.23
  111.  
  112. *** new to v1.23
  113. Find Objects:find linedefs/sectors/things by trigger/action/type
  114. Texture replace:map-wide replace, specify or from list (TXTRCONV.TXT)
  115. Grab style:grabs sector (or linedef) style into the current style
  116. new extended multiple-selection structure
  117. runability test for Play Map (CTRL-F9)
  118. edit obj-info-bar with mouse
  119. many tiny improvements..
  120.  
  121. *** new to v1.22
  122. XMS support; create larger maps with less base memory.
  123. Vertex and LineDef modes merged; (edit faster)
  124. much nicer (and possibly faster) enhanced map display
  125. scans WAD dir entries more leniently
  126. mouse pointer pictures
  127. Auto-lift implemented
  128. deathmatch/altdeath available for playmap (nodes 1)
  129. auto-stairs outline when placing
  130. missing "PTX-6.DAT", "FLORLIST.DAT" bug solved
  131. DOOM II textures reorganized
  132. lotsa other stuff..
  133. bugs fixed from v1.21b
  134.  
  135. *** new to v1.21
  136. to v1.21b:bugs fixed:ESC from multi,choose texture, etc.
  137. new play-map panel: toggle/adjust options & choose level
  138. many tiny improvements
  139. bugs fixed from v1.20
  140.  
  141. *** new to v1.20
  142. DOOM II support!
  143. Multiple-selection
  144. DOOM2WAD utility provided: simple DOOM I <-> DOOM II converter.
  145.     only changes map directory entry.
  146. Improved process handling (EDMAP->EDMAPSYS<->DOOM?<->etc)
  147. faster: initialization, graphics text, viewer, etc
  148. auto-configuring; will load EDMAPCFG if bad *.CFG
  149. INFO.BAT file to examine a child-process environment
  150. texture-aligning using the viewer: handy; view and adjust the 
  151.     texture exactly as it would appear in DOOM.
  152. THing radius circles.  color, too.
  153. Auto-saving options, undo feature.
  154. many, many other improvements.
  155.  
  156. **** new to v1.12:
  157. If play-skill level 0 is chosen, a panel will prompt for a
  158.     skill level for play-map.
  159. The /dir paramter now lists entry names correctly.
  160.  
  161. **** new to v1.11:
  162. Two bugs in auto-stairs fixed: the block-all bit is off, and
  163.     the step-top texture now uses the correct panel.
  164. The center button on 3-button mouses (mice?) should select/
  165.     de-select (as pressing enter).  this is untested.
  166. The File-opening routine has been replaced by code written
  167.     by Scott Bussinger (Compuserve 72247,2671) EXTEND5.ZIP
  168.     this allows about 100 additional PWAD files to be used.
  169.     (100 is impossible, since there are only 27 maps)
  170. Some routines have been rewritten in assembler for speed.
  171.  
  172. *** new to v1.10
  173. Much better error checking; checks for:
  174.     texture:Missing textures/Hall of Mirrors,
  175.         Medusa effect: multi-patch on 2S main
  176.         Tutti Fruitti (1): short texture
  177.         Tutti Fruitti (2): transparent above/below
  178.     linedef:Short lines
  179.         Long Wall Error (LWE)
  180.     things :heights,
  181.         in a sector
  182.     associations:triggers when needed,
  183.         teleporter destinations
  184.     begin/end:all starts & one or more end.
  185.     Errors can be listed or displayed
  186. Viewer: views walls, floors, sprites, and patches in the normal
  187.     DOOM palette.  can be used to select textures.
  188. On-line help: press F1, help screen is almost always available.
  189. Automatic Stairs: automatically contructs a staircase within
  190.     or outside any sector.  Can be triggered to rise out
  191.     of the floor.  many options, all automatically saved.
  192. Automatic Door: like stairs, makes a door.
  193. Polygon creation: makes polygon sectors (also adjusts textures)
  194. Texture align: aligns textures, either by sector or linedef
  195. much better/easier file-handling.
  196. Sector resizing and rotating
  197. Map-wide editing: lights, X/Y/Z proportions & origin.
  198. sector retexturing: press Alt-F8
  199. preferences panel: saves mouse data, verifys, play level, etc.
  200. pop-up calculator: If Num-lock is on, so is the calc (almost)
  201. new panels, better algorithms (faster, too)
  202. easier to use
  203. many many other features
  204.  
  205. *** new to v1.02
  206. Error checking (including, of course, texture checking)
  207. Independant batch-driven builder making EdMap more flexible
  208. Better process-handling; switches between EdMap/builder/DOOM better
  209. "Load Latest PWAD" now scans the PWAD dir for the latest "*.WAD" file
  210. Sector deletion
  211. Some of the redraw routines were scrapped & rewritten in assembler
  212. better menus in full-screen mode (does it look like a NeXT yet?)
  213. some other bugs fixed.
  214.  
  215. *** new to v1.01
  216. Reverse mouse buttons now works
  217. Reverse panning control
  218. More informative load map; dots mark updated levels & "reload" marked.
  219. Adjustable grid & snap (by config)
  220. Fully supports other map levels, not just E1M1
  221. Faster "enhanced map" redraw
  222. Colors in object info bar
  223. some other bugs fixed..
  224. +
  225. What's New
  226.  
  227.  
  228. ============
  229. #old-EDMAP BASICS
  230. ============
  231. Editing in EdMap is done in one of four modes: VX (vertex) and LD (linedef/wall), SE (sector/room), and TH (thing).  Normally the nearest object to the mouse is highlighted, this is the Current object. If Control-Enter is pressed, the Current object becomes the Selected object and remains selected until enter is pressed again or the mode is changed. Most editing is done on the current object, but some operations require a selected object. Pressing Enter alone or holding Control while clicking on the object multiple-selects the current object. Multiple-selection allows a list of objects to be edited instead of one at a time.
  232. +
  233. Unofficial DOOM Specs
  234. object basics
  235. add/split
  236. multiple select
  237. editing objects
  238. Menu
  239. display arrangement
  240. help
  241. What's New
  242. Files
  243. ============
  244. EDMAP BASICS
  245. ============
  246. $CEdMap v1.41
  247. $u
  248. $Cby Jeff Rabenhorst
  249. $C(araya@wam.umd.edu)
  250. $0
  251. EdMap is a DOS-based utility that can be used to create and play maps for DOOM, DOOM II and Heretic by id Software.  This is not an id Software product.
  252. $uAll help-topics prefixed with "UDS" are written by Matt Fell, not Jeff Rabenhorst, author of EdMap.  Click on Unofficial DOOM Specs for more information
  253. +
  254. Editing maps
  255. Unofficial DOOM Specs
  256. Menu
  257. Setup
  258. Help
  259. Files
  260. Display arrangement
  261. /
  262. What's New
  263.  
  264. ====
  265. FILES
  266. =====
  267. The EdMap base package includes enough files necessary to run the editor.  Additional packages are available for TC/theme installation and builder conversions, but they are not described here (but they may include additional help topics; check the documentation or try the help search).
  268. +
  269. Programs
  270. Batch files
  271. Utilities
  272. ====
  273. BATCH FILES
  274. ====
  275. $1BUILD.BAT  This file is run to build the map.  Running BUILD HANGER18, for example will create the BSP data for the PWAD "HANGER18.WAD" in the current directory.  If the alternate build was chosen, the second parameter passed would be "ALTBUILD".  The remaining parameters are used by EdMap.
  276. INFO.BAT  This file is only run from the System resources panel to provide information about the shell environment EdMap provides.  "I"nfo "S"ystem resources "I"nfo.bat.
  277. +
  278. Files
  279. ====
  280. UTILITIES
  281. ====
  282. $1STUFFBUF.EXE  This utility inserts keystrokes into the input stream to simulate pressed keys.  This is used in BUILD.BAT before loading the game during a play-map to skip the "This is a modified.." message at startup.  This utility may also be used to skip the input many builders require.  Running STUFFBUF DIR! will simulate pressing D-I-R and pressing enter (exclamation mark = enter) to get a directory listing.
  283. VGA50.EXE  This is a simple utility that loads the 8x8 character set into the normal VGA 360x400 text resolution screen to use a 80x50 character display.  This is used by INFO.BAT (and possibly BUILD.BAT) to double the screen size.
  284. +
  285. Files
  286. ====
  287. PROGRAMS
  288. ====
  289. $1EDMAP.EXE and EDMAPSYS.EXE  These files make together make up the editor program.  EDMAPSYS.EXE is not to be run independently.  To run the editor, run EDMAP.EXE, it will run EDMAPSYS.EXE as needed.  Run EDMAP /? for information.
  290. $TSpecial note: Scroll-Lock may be used to suspend child-processes.$t
  291. EDMAPCOM.EXE  This file is another subordinate program of EDMAP.EXE.  This program is used in BUILD.BAT to report back to the parent process and change control variables.
  292. EDMAPCFG.EXE  In addition to being the installation program for the EdMap system, it houses all the utilities not present in EDMAPSYS.EXE.  EdMap will run EDMAPCFG.EXE as needed.  
  293. $TRunning EDMAPCFG REBUILD will test all data files and update or create any outdated or missing files.  This should be unnecessary, however, as EdMap will do this on startup if needed.$t
  294. +
  295. Files
  296. ====
  297. SETUP
  298. ====
  299. EdMap may be configured at the system level, using EDMAPCFG.EXE, or at the program level, using the Preferences panel.  Both save to the configuration file (EDMAP.CFG, if none is specified).  From within the program, "I"nfo "P"references opens the preferences panel, from which other options panels may be opened.  "I"nfo "E"dit config will run EDMAPCFG, allowing changes to the configuration file not available from within the editor.
  300. +
  301. Programs
  302. Preferences
  303.  
  304. ====
  305. Menu
  306. ====
  307. $B000010/linesTo choose a selection from a menu, either click on the menu with the mouse or press the key of the first letter of that selection.  For example, press "M" to expand the "Map Utilities" menu.  From here, pressing "S" would select "Shift Map".  Left-clicking will select, right clicking on the menu will provide help for that selection.
  308. In full-screen the menus still appear when brought up (by hitting a key) but are not displayed when not in use.
  309. +
  310. Info
  311. File (map)
  312. WAD list
  313. Edit
  314. Map utilities
  315. Sectors
  316. Automatic
  317. Display
  318. Check
  319.  
  320. ====
  321. INFO
  322. ====
  323. /$B001002/lines
  324. This provides general information about the map and the status of EdMap itself.  Also the Preferences panel can be used to adjust some of the defaults in the config file that are not accessible from EDMAPCFG.  
  325. +
  326. Menu
  327. About EdMap
  328. Help
  329. Calculator
  330. Map Information
  331. System Information
  332. Load config file
  333. Edit config (EDMAPCFG)
  334. Preferences
  335.  
  336. ===========
  337. ABOUT EDMAP
  338. ===========
  339. The About panel displays version information about EdMap.
  340. +
  341. Info
  342.  
  343. ====
  344. HELP
  345. ====
  346. This help panel provides assistance for the current feature.  While in almost every panel, F1 may be pressed to activate the help panel.  Clicking on the "Ok" button, pressing Enter or ESC will leave help and return to the previous function.  If memory is low a disk file will be created to store memory, unless there is too little memory to do even this.
  347. Whenever in any panel, buttons on the panel are used to input information.  Use these buttons by moving the mouse arrow over them and click the left button (unless the buttons are switched).  ESC may be pressed from any panel to abort, and Enter may be pressed to accept.
  348. If a panel is active and an error occurs, but the active panel must stay in the foreground, the message "error" will appear.  (Messages are in a red box in below the menu in normal view).  When the panel is done the error will appear in a normal panel.
  349. +
  350. Info
  351. EdMap basics
  352.  
  353. ===============
  354. CALCULATOR
  355. ===============
  356. A simple pop-up 4-function calculator is available.  Num Lock controls the calculator; while Num Lock is on the calculator is active.  (This may be disabled via the Preferences panel.)  The calculator uses all the keys on the numeric keypad.
  357. +
  358. Info
  359.  
  360. ===============
  361. MAP INFORMATION
  362. ===============
  363. The Map Information panel displays statistics about the map.
  364. +
  365. Info
  366.  
  367. ==================
  368. SYSTEM INFORMATION
  369. ==================
  370. System Resources provides information concerning the state of the operating system, including memory usage.
  371. +
  372. Info
  373.  
  374. ==================
  375. LOAD CONFIG FILE
  376. ==================
  377. A new configuration file may be loaded and used from this option.
  378. +
  379. Info
  380.  
  381. ====
  382. Edit config (EDMAPCFG)
  383. ====
  384. Edit the active configuration file.  Current PWADs will be restored, but directories and filenames may be changed.
  385. +
  386. Info
  387.  
  388. ===========
  389. PREFERENCES
  390. ===========
  391. The Preferences panel can be used to customize the editor.  Mouse settings, automatic saving, verifications and other options are controlled from this panel.  Additional option panels are also available from here: checking and snap options and palette adjustment panels.  Changes are saved to the config file.
  392. +
  393. Info
  394. Checking options
  395. Snap options
  396. Palette adjustment
  397.  
  398. ==================
  399. CHECKING OPTIONS
  400. ==================
  401. This panel determines how the integrated checker examines the map.  No option refers to a single test; each toggles a set of checks performed.  The Long-Wall-Error (LWE) value specifies what length a non-orthogonal wall must be greater than to trigger a LWE warning.
  402. +
  403. Preferences
  404.  
  405. ==================
  406. SNAP OPTIONS
  407. ==================
  408. The snap options panel specifies when vertices should snap to the current snap grid.
  409. +
  410. Preferences
  411.  
  412. ==================
  413. PALETTE ADJUSTMENT
  414. ==================
  415. The Palette panel can be used to adjust the hues of 16 colors.  This does not change the color assignments; only the palette values.
  416. +
  417. Preferences
  418.  
  419. ==========
  420. FILE (MAP)
  421. ==========
  422. $B002003/linesThe File/Map menu handles the currently loaded map and control out of EdMap.  This menu controls only the current PWAD; see WAD``list for more on managing the active PWADs.
  423. +
  424. New map
  425. Open map file
  426. Save map data
  427. Load PWAD map
  428. Rename map
  429. Build & save map
  430. Alternate build
  431. Play map
  432. Quit to DOS
  433. Menu
  434.  
  435. =======
  436. NEW MAP
  437. =======
  438. New Map will clear the memory of the current map and start fresh with a new map.  The new map is a 64x64 room (using the current styles) with the Start-1 object at the origin.
  439. +
  440. File (map)
  441.  
  442. =============
  443. OPEN MAP FILE
  444. =============
  445. This displays all the *.WAD files in the pwad directory (as specified in EDMAPCFG), so a PWAD map file may be chosen and loaded.  The files may be sorted by name or timestamp (last save).  
  446. Files may also be deleted from this panel.  Highlight the map to be deleted with the mouse and press delete.
  447. +
  448. File (map)
  449.  
  450. =============
  451. SAVE MAP DATA
  452. =============
  453. Saves the current map to the PWAD directory.  If the map has no filename a panel will ask for one.    The main IWAD (DOOM.WAD/HERETIC.WAD) file will not be written to.
  454. Saving the map does not build the BSP data necessary to play the map.  See Build & save map about creating the BSP.
  455. +
  456. Build & save map
  457. File (map)
  458.  
  459. =============
  460. LOAD PWAD MAP
  461. =============
  462. This displays all the maps (E1M1 to E3M9) and loads one according to the PWAD list.
  463. +
  464. File (map)
  465.  
  466. =================
  467. RENAME MAP
  468. =================
  469. Renames the map to a different episode/mission.  Generally single maps are E1M1; the first mission.  If separate maps are concatenated, however, each must be under a separate mission.
  470. +
  471. File (map)
  472.  
  473. =================
  474. HARD COPY (PRINT)
  475. =================
  476. (may not be available yet)
  477. Prints the current map to the printer on the port specified in EDMAPCFG.
  478. +
  479. File (map)
  480.  
  481. ================
  482. BUILD & SAVE MAP
  483. ================
  484. Saves the current map and builds the BSP data necessary to play it.  If the build fails to complete for any reason, the map will be automatically reload as it was prior to the build.
  485. +
  486. File (map)
  487. Alternate build
  488.  
  489. ================
  490. ALTERNATE BUILD
  491. ================
  492. Exact same as a normal build ("F"ile "B"uild), except that the "ALTBUILD" parameter is passed to BUILD.BAT.  This may build a reject table or archive the WAD.
  493. +
  494. Build & save map
  495. File (map)
  496.  
  497. ========
  498. PLAY MAP
  499. ========
  500. Saves, builds, and plays the current map.  Similar to Build``&``save``map, but instead of returning directly to the editor, the game exe (as specified in EDMAPCFG) is loaded with the current map.  The game will start in the map, skipping the demos.  The skill level chosen is specified in the Preferences panel.  If saving and/or building is unnecessary, it will be skipped.  Additional parameters may be added using EDMAPCFG, but this is unnecessary.
  501. Note that id software is not responsible for any edited maps.
  502. +
  503. Preferences
  504. Programs
  505. File (map)
  506.  
  507. ===========
  508. QUIT TO DOS
  509. ===========
  510. Exits EdMap. If the map has unsaved changes, a panel will ask what to do.
  511. +
  512. File (map)
  513.  
  514. ========
  515. WAD LIST
  516. ========
  517. /$B003004/lines
  518. This menu handles the PWAD files.  Loading, creating and listing PWADs is done using WAD``list.  While the File``(map) menu controls the current map/single PWAD, WAD``list handles all of the active PWAD files.
  519. +
  520. List WADs
  521. Save as PWAD...
  522. Add PWAD file
  523. PWADs
  524. Menu
  525.  
  526. =========
  527. LIST WADS
  528. =========
  529. Lists the active PWAD files and the maps they contain (that are not outdated by other PWADs).  Information may be provided from this list or PWADs may be removed.
  530. +
  531. WAD list
  532. PWADs
  533.  
  534. =============
  535. ADD PWAD FILE
  536. =============
  537. Adds a file to the PWAD list as if it were included on the command line as a parameter.  Open``map``file preforms the same function (and is easier to use).
  538. +
  539. Open map file
  540. WAD list
  541.  
  542. ===============
  543. SAVE AS PWAD...
  544. ===============
  545. Renames the map file and saves it.  After this function, all saves will be to the new file.
  546. +
  547. WAD list
  548.  
  549. ====
  550. EDIT
  551. ====
  552. /$B004005/lines
  553. The Edit menu provides control for manipulating objects on the map.
  554. +
  555. Add/Split
  556. Delete/merge
  557. Undo from last save
  558. Shift object
  559. Find objects
  560. Goto object
  561. Next object
  562. Previous object
  563. Tag line to sector
  564. Menu
  565.  
  566. =========
  567. ADD/SPLIT
  568. =========
  569. This function serves different purposes for various modes.
  570. In Vertex mode this is a vertex-break.  All sectors attached to the current vertex break and recede from the that vertex.  This is extremely useful for correcting mistakes.
  571. In LineDef mode this will split the current linedef into two halves.
  572. In Sectors mode a new sector is created on insert.  Normally sectors are created in the void and then added to the map, but if there is a sector currently highlighted during the insert, then the new sector will be made within that sector.
  573. In Things mode this will duplicate the current Thing object.  If there is no current Thing, a new object is created.
  574. +
  575. Object basics
  576. Edit
  577.  
  578. ======
  579. DELETE/MERGE
  580. ======
  581. Like Add/Split, the result of Delete depends on the mode.
  582. This does nothing in Vertex mode and only deletes the current linedef if that linedef is not supporting any sector or action.
  583. In Sectors mode, deleting removes the selected sector.  If the sector is within another sector, void is left where the sector used to be, surrounded by 1-sided linedefs.  If the sector was in void itself, nothing is left.
  584. In Things mode, the current Thing is deleted.
  585. +
  586. Object basics
  587. Edit
  588.  
  589. =========
  590. Shift object
  591. =========
  592. A derivative of normal dragging, shifting allows objects to be moved very small increments for accurate placing.  The arrow keys move the object(s), and the number keys (1-9) adjust the step size.  As with normal dragging, pressing ESC will abort and undo the changes.  The step size is saved to the configuration file.
  593. +
  594. Edit
  595.  
  596. ================
  597. Undo from last save
  598. ================
  599. Reloads the map data, restoring it to the state of its last save.
  600. +
  601. Edit
  602.  
  603. ============
  604. FIND OBJECTS
  605. ============
  606. Multiple-selects all objects that share some characteristic.  The previous multiple-selection list will be cleared before this function is called.
  607. LineDefs may be selected by trigger (tag) number or action.  Sectors by trigger, action or type.  Thing-objects may be found by type.
  608. +
  609. Edit
  610.  
  611. ===========
  612. GOTO OBJECT
  613. ===========
  614. Locates the given object by number.
  615. +
  616. next object
  617. previous object
  618. Edit
  619.  
  620. ===========
  621. NEXT OBJECT
  622. ===========
  623. Locate the next object (by number) if it exists.
  624. +
  625. previous object
  626. Find objects
  627. Edit
  628.  
  629. ===============
  630. PREVIOUS OBJECT
  631. ===============
  632. Locate the previous object (by number) if it exists.
  633. +
  634. next object
  635. Find objects
  636. Edit
  637.  
  638. ==================
  639. TAG LINE TO SECTOR
  640. ==================
  641. Associates a linedef to a Sector to perform an action.  If the linedef does not already have an action, one may be chosen first.  The LineDef that holds a switch, for example, could be tagged to a sector that lowers its floor.
  642. +
  643. Edit
  644. /
  645. UDS [4-3-2] LINEDEF types
  646. =============
  647. MAP UTILITIES
  648. =============
  649. /$B005006/lines
  650. Allows map-wide editing of the map.
  651. Shifting the map (or origin), adjusting the map size and changing the light levels can be done using Map``utilities.
  652. +
  653. Shift map (X/Y/Z)
  654. Expand/reduce map
  655. Light adjustment
  656. Texture replace
  657. Menu
  658.  
  659. =================
  660. SHIFT MAP (X/Y/Z)
  661. =================
  662. Shift map allows each Vertex and Thing object to be shifted on their X and Y coordinates.  Sector floors and ceilings may also be shifted up or down (Z).  Positive values shift right/east for X, north for Y, and up for Z.
  663. Centering the map will enter values to move the origin to the midpoint of the extreme vertices (not the mean average).  After pressing the center button, the values may be changed before shifting.
  664. +
  665. Map Utilities
  666.  
  667. =================
  668. EXPAND/REDUCE MAP
  669. =================
  670. Expanding (and reducing) the map is done by changing the X,Y, and Z percent values.  Values above 100% expand the map on that axis, below 100% reduce, and a value of 100% will remain unchanged.
  671. +
  672. Map Utilities
  673.  
  674. ================
  675. LIGHT ADJUSTMENT
  676. ================
  677. The overall light intensity for the entire map may be changed using the Map light adjustment panel.  Two variables determine what each new sector light value will be.  A (amplify) is a percent-value which is multiplied by the old light value, and B (brighten) is added to this product.  The formula is:
  678. New``Light`=`Old``Light x A/100 + B.
  679. If A is 100% and B is zero, no light is changed.
  680. +
  681. Map Utilities
  682.  
  683. ===============
  684. TEXTURE REPLACE
  685. ===============
  686. Searches the entire map and replaces every occurrence of a specified texture with another texture.  This can be done by selecting the specific texture to find or by using a list to convert any texture on the list.
  687. The text file that contains the list of texture conversions is TXTRCONV.TXT, as specified by string #276 of  TEXTLIST.TXT.
  688. This feature can be useful for converting DOOM I maps that use textures not found in DOOM2.WAD to run in DOOM II.
  689. +
  690. Map Utilities
  691.  
  692. =======
  693. SECTORS
  694. =======
  695. /$B006007/lines
  696. Sectors are homogeneous areas on the map where players or monsters may exist.  Each sector may have only one floor and one ceiling.  Any space not in a sector is void and inaccessible.  A single sector may be a simple room, but generally rooms are more than one.  Sectors may also be inside other sectors.
  697. The sectors menu provides control for creating and editing sectors, it also controls sector styles.
  698. +
  699. Polygon
  700. Rotate
  701. Size
  702. Texture style
  703. Edit styles
  704. Grab style
  705. Align textures
  706. Configure align
  707. Menu
  708. Object basics
  709. UDS [4-9] SECTORS
  710.  
  711. =======
  712. POLYGON
  713. =======
  714. After selecting polygon, the center of the polygon must be placed and the polygon panel will appear.  The number of sides and the radius may then be entered.  The number of sides can be no less than 3, and no more than 40.  The number of sides should be as few as possible; more sides take resources: (size of the map is larger, game may run slower, etc.)  The radius of the polygon is measured from the center to each vertex, not to the LineDefs.
  715. +
  716. Sectors
  717.  
  718. ======
  719. ROTATE
  720. ======
  721. Sector rotation and resizing are handled similar to a normal drag.  Once sector rotation is enabled, "rotate" will appear in the message window.  A sector may be picked to rotate just as it would be picked up for dragging.  The mouse will then snap to the lower right corner of the sector.  The sector will pivot on its midpoint, following the mouse until it is dropped, just as dragging.  A panel will verify that the change is to be kept.  If rotation is enabled accidentally, selecting sector rotation again will return to normal drag.  Some Thing objects may also be rotated.
  722. +
  723. size
  724. Sectors
  725.  
  726. ====
  727. SIZE
  728. ====
  729. Sector resizing and rotating are both handled similar to a normal drag.  "Resize" appears in the message window when sector resizing is enabled.  Just as dragging, the sector to be changed must be picked up, edited (by moving the mouse), and dropped again.  When a sector is picked up for resizing, the mouse will snap to the lower right corner (as in rotating), and the sector will fit in the imaginary box whose lower right corner follows the mouse.  Click to drop, and verify that the change is correct.  The sector will not flip (to be mirror-image or upside-down), if the mouse passes the center of the sector, instead another corner of the box will follow the mouse.  If resizing is enabled accidentally, selecting sector resizing again will return to normal drag.  
  730. +
  731. rotate
  732. Sectors
  733.  
  734. =============
  735. TEXTURE STYLE
  736. =============
  737. This function retextures the ceiling, floor, and all walls of the current sector with the sector style. 
  738. +
  739. Align textures
  740. Sectors
  741.  
  742. ===========
  743. EDIT STYLES
  744. ===========
  745. The sector styles list may be edited in two ways: either adding/deleting records, or by rearranging existing records.
  746. Adding or deleting style records is done after selecting a one-sided LineDef.  The Edit sector styles panel then displays the style associated with that LineDef so it may be added to the list.  Existing records may also be deleted from this panel, but a LineDef must still be selected to bring up the panel.
  747. Rearranging style records must be done in sectors mode.  A list of all existing styles will appear, and the chosen style will be moved from its current place.  Again the list will be displayed, and the chosen slot will be the destination for the first record.  The two styles will swap places in the styles list.  The first record will always be the default style when EdMap starts up.
  748. If there are no records in the styles file (or the file does not exist), a new file will be created when a style is added.
  749. +
  750. Sectors
  751.  
  752. ==========
  753. GRAB STYLE
  754. ==========
  755. Examines the current sector (or LineDef) and guesses what the best style associated with that object is, and writes this data to the current style.
  756. +
  757. Sectors
  758.  
  759. ==============
  760. ALIGN TEXTURES
  761. ==============
  762. Align texture automatically adjusts the x-offset of adjacent sidedefs whose textures are the same to make the wall texture appear as one.  Use in either linedef or sectors mode.
  763. If done in sectors mode this will adjust all wall textures facing the sector.  However, since every texture may not be correctable (as in a round room for example), this may leave "seams" where the last texture has already been aligned.
  764. If used in linedef mode, "seams" can be placed.  In linedef mode the current (one-sided) line texture is used as the starting point, whose x-offset is 0.  The next texture to the right is adjust accordingly, and so on, until the first texture is reached again or a new texture is used.  This way the "seam" (if any) is always on the left of the initial texture.
  765. Note that in addition to testing the main texture, both the upper/above and lower/below textures will be checked for a texture match in order to continue aligning.
  766. +
  767. Sectors
  768. Aligning using the viewer
  769.  
  770. =========
  771. CONFIGURE ALIGN
  772. =========
  773. Specifies which axis (X or Y) to align, or both.
  774. +
  775. Sectors
  776.  
  777. =========
  778. AUTOMATIC
  779. =========
  780. /$B007008/lines
  781. The Automatic menu can be used to convert or create complex structures on the map.  All changes made in any of the panels are saved to the config file.
  782. +
  783. Lift
  784. Door
  785. Stairs
  786. Teleporter
  787. Menu
  788.  
  789. ====
  790. LIFT
  791. ====
  792. Converts the current sector into a lift.
  793. The lift panel controls whether the lift is repeatable and which textures are used.  The Floor will be retextured according to the panel if the "Use floor?" option is enabled.
  794. +
  795. Automatic
  796.  
  797. ====
  798. DOOR
  799. ====
  800. The Door feature converts the current sector into a door using specifications in the Door panel.  All textures and other options in the Door panel are saved.
  801. Door texture is what the door will look like when closed.  Sill texture is what the wall that the door slides up on will look like.  The bottom texture is the texture on the bottom of the door when it is open.  Key specifies what key, if any, is needed to open the door.  Doors will close 6 seconds after it opening unless it is set to stay open.  A moving sill will rise with the door when it opens.
  802. +
  803. Automatic
  804.  
  805. ======
  806. STAIRS
  807. ======
  808. The Stairs option creates a new set of sectors that may either be a staircase or a floor that when triggered rises into a staircase.  After accepting the Stairs panel, place the first step of the staircase.    If created within an existing sector, only the floor will be changed; the ceiling will appear to be the same.  If made in the void, the current sector style will be used for data not specified in the Stairs panel.
  809. The panel specifies textures, sizes, and other attributes needed to construct the staircase.  Step top and step side textures modify only the steps; walls are taken from the style.  Rise, depth and width determine size of each step.  Ceiling height (if created in void) is this value above the floor of the highest step.  The staircase may go up, right, down or east.  
  810. There are special considerations for staircases that rise out of the floor.  First: each step must rise to 8 high.  Second: Modifying the shape of the steps can disable its operation.  Experiment; sometimes it will work, but it cannot be guaranteed.
  811. +
  812. Automatic
  813.  
  814. ======
  815. TELEPORTER
  816. ======
  817. The automatic teleporter tool functions two ways, depending on whether it was used in linedef mode or sectors mode.
  818. From linedef mode, a quick-n-simple teleporter association is made.  The current linedef is associated to the sector tagged, and a teleporter destination is placed on the point indicated facing the direction specified.
  819. From sector mode, the Teleporter panel is used.  After accepting the settings, two teleporter pads are placed.
  820. +
  821. Automatic
  822. =======
  823. DISPLAY
  824. =======
  825. /$B008009/lines
  826. The display menu offers control over the normal viewing screen.  Additional information may be displayed or changed from this menu.
  827. +
  828. Enhance map
  829. Full screen
  830. Snap/grid
  831. Grid on/off
  832. Origin on/off
  833. Center map
  834. Viewer
  835. Refresh display
  836. Menu
  837.  
  838. ===========
  839. ENHANCE MAP
  840. ===========
  841. While in enhanced map mode, the normal map drawing routines will shift sectors according to altitude, and draw some lines for walls, for a 3-dimensional effect.  Many operations are simplified in this view; breaks in one-sided walls are drawn easy to see, and merging sectors is easier since the wall disappears when the sectors are connected.  Redrawing the map in enhanced view is not as fast as normal view because of the extra lines and calculations; this is may be noticeable when panning the map.  The shifting is not proportional.  It is always fixed so when the map is zoomed in, the walls do not extend off the screen, and so it is easier to determine between walls and floors.
  842. +
  843. Display
  844.  
  845. ===========
  846. FULL SCREEN
  847. ===========
  848. Full screen display removes the menu and the information bar, leaving the entire screen to displaying the map.  The menu may still be used with the keyboard.  The object information bar will either still edit objects or it will be locked to prevent accidental changes.  Whether or not it is locked is set using EDMAPCFG.  Switching between full and normal views can be done using the mouse pad, the menus: "D" (Display) "F" (Full screen), or the hot-key: Ctrl-S.
  849. +
  850. mouse pad
  851. Display
  852.  
  853. =========
  854. SNAP/GRID
  855. =========
  856. Using the Grid/snap sizes panel, the blue dot grid and the drag snap grids may be adjusted.
  857. The grid is a grid of blue dots draw on the map to help align objects.  If the map is zoomed out too far so the grid dots become too dense, the grid will not be drawn.  (This also means that a grid of 2 points may never be drawn.)  The grid may also be turned off using Grid``on/off.
  858. The snap grid is used when dragging any object.  All vertices of the current object (or Thing) will snap to the closest point on the snap grid while moving.  This helps with merging since dragging need only be as accurate as the size of the snap grid.  Although the minimum size is 2 points, it is generally best to keep the snap grid between 4 (or 8) and 32 points.  Too low and merging vertices becomes difficult, too high and new sectors snap into oblivion.  The snap grid is unrelated to the normal dot grid.
  859. +
  860. Grid on/off
  861. Display
  862.  
  863. ===========
  864. GRID ON/OFF
  865. ===========
  866. The normal dot grid may be toggled on or off with this function.  The screen refresh may be slightly faster and a small amount of memory is freed when the grid is off.
  867. +
  868. Snap/grid
  869. Display
  870.  
  871. =============
  872. ORIGIN ON/OFF
  873. =============
  874. Toggles drawing the origin (0,0) on the map.  Will not noticeably affect performance or memory.
  875. +
  876. Snap/grid
  877. Grid on/off
  878. Display
  879.  
  880. ==========
  881. CENTER MAP
  882. ==========
  883. Centers the map on the mean average of all vertices.
  884. +
  885. Display
  886.  
  887. ======
  888. VIEWER
  889. ======
  890. The viewer displays wall, floor (ceiling), sprite, and patch graphics exactly as they would appear in the game.
  891. Wall graphics are the textures used on every wall in the game.  Some textures are partially transparent and some are animated.  Transparent graphics may only be used on the main texture for 2-sided linedefs, where a texture is unnecessary.
  892. Every sector must have two floor graphics: one on the floor and one on the ceiling.  Some floor textures are also animated and F_SKY appears transparent by showing scenery.
  893. Sprites are any graphic images of Things that are displayed within a room.  Monsters, weapons, obstacles, etc. are all sprite graphics.
  894. Switch between display modes by pressing left and right, choose textures by pressing up/down/PgUp/PgDn or by pressing the first letter of the texture name.  Press Enter to select, ESC to abort.
  895. If external graphics (TEXTUREx) are used, pressing Insert while viewing wall textures will switch between the IWAD names and new texture names.
  896. +
  897. Display
  898. Aligning using the viewer
  899.  
  900. ==========
  901. REFRESH DISPLAY
  902. ==========
  903. Redraws the entire screen.
  904. +
  905. Display
  906.  
  907. =====
  908. CHECK
  909. =====
  910. /$B009010/lines
  911. EdMap can test for several errors that may make the map less playable.
  912. Transparent textures, multi-patch textures, hanging textures, short textures, short lines, long lines, missing tags, missing things, thing heights, and map exits can all be checked.
  913. +
  914. Error list
  915. Quick check
  916. Check all
  917. Textures
  918. Associations
  919. Heights/widths
  920. LineDefs
  921. Begin & end
  922. Menu
  923.  
  924. ==========
  925. ERROR LIST
  926. ==========
  927. Compiles a list of all errors found on the map by calling the individual checks.  Warnings may be disabled using the Preferences panel.
  928. +
  929. Preferences
  930. Check
  931.  
  932. ===========
  933. QUICK CHECK
  934. ===========
  935. Quick check browses over the map, but does not check for every possible error.
  936. +
  937. Check
  938.  
  939. =========
  940. CHECK ALL
  941. =========
  942. Checks the entire map for errors.
  943. After each error, the check may be stopped or resumed to find the next error, if any.
  944. +
  945. Check
  946.  
  947. ========
  948. TEXTURES
  949. ========
  950. Checks textures:
  951. Hall of Mirrors/Missing textures, if a texture is used, the texture name will be checked to see that it exists in DOOM.
  952. Medusa effect: a multi-patch texture on a 2S (2-sided) main wall.
  953. Tutti-Fruitti effect: (1) short texture on main, cannot be tiled evenly, (2) transparent textures on above/below surfaces.
  954. +
  955. Check
  956.  
  957. ============
  958. ASSOCIATIONS
  959. ============
  960. Tests that all LineDefs that activate sectors and need a trigger are tagged to at least one sector.  Also tests for appropriate teleporter destinations.
  961. +
  962. Check
  963.  
  964. ==============
  965. HEIGHTS/WIDTHS
  966. ==============
  967. Tests Thing objects (monsters, players, teleporter destinations, etc.) that must be in a sector at least as tall as they are.
  968. Widths are not tested.
  969. +
  970. Check
  971.  
  972. ========
  973. LINEDEFS
  974. ========
  975. LineDefs are walls that bound sectors and are bound by vertices.  Each LineDef has one or two SideDefs, one for each side.  Two-sided LineDefs (2S) separate two sectors, while one-sided (1S) lines border void and one sector.
  976. The LineDef check tests LineDefs:
  977. Long Wall Error (LWE): non-orthogonal linedefs that are very long (as defined in the checking option panel) can cause problems in the game engine.  Split them into shorter lines to prevent any problem.  This produces a warning, not an error.
  978. Short/zero-length lines: walls too close together can cause problems.  zero-length is obviously an error and should never occur.
  979. +
  980. Check
  981. UDS [4-3] LINEDEFS
  982.  
  983. =================
  984. BEGIN & END
  985. =================
  986. Tests for all start positions on the map.  Start 1-4 and at least 4 deathmatch starts should be included.  Also tests for at least one exit.
  987. +
  988. Check
  989.  
  990. ===============
  991. EDITING MAPS
  992. ===============
  993. Maps are modified by manipulating objects of each of the four modes (vertices, linedefs, sectors and things)  Objects may be created (and deleted), edited (via the object info bar) or dragged.
  994. +
  995. Object basics
  996. /
  997. Creating and deleting objects
  998. /
  999. Editing objects
  1000. /
  1001. Dragging objects
  1002.  
  1003. ===============
  1004. CREATING AND DELETING OBJECTS
  1005. ===============
  1006. Pressing Insert or holding the right button while and tapping the left will add/split an object.  Delete and backspace will delete/merge the current object(s).
  1007. These function produce different results, depending on mode and whether objects are multiple-selected.  
  1008. Below are four tables describing how these functions operate.
  1009. $u
  1010. +---------------------------------------
  1011. | SINGLE OBJECT
  1012. |                  Add/Split
  1013. | +---------+---------------------------
  1014. | | VERTEX   ``| Vertex-Break                  
  1015. | | LINEDEF   | Splits the current linedef    
  1016. | | SECTOR   ``| Adds a sector                 
  1017. | | THING     | Adds a thing                  
  1018. | +---------+---------------------------
  1019. |                  Delete/Merge
  1020. | +---------+---------------------------
  1021. | | VERTEX   ``| Deletes lone vertices         
  1022. | | LINEDEF   | Deletes unsupporting linedefs 
  1023. | | SECTOR   ``| Deletes the current thing     
  1024. | | THING     | Deletes the current thing     
  1025. | +---------+---------------------------
  1026. $!$0
  1027. These tables define these functions for multiple-selected objects:
  1028. $u
  1029. +---------------------------------------
  1030. | MULTIPLE-SELECTED OBJECTS
  1031. |                  Add/Split 
  1032. | +---------+---------------------------
  1033. | |  VERTEX  ``| Multiple vertex-breaks       
  1034. | | LINEDEF   | Selects supporting vertices  
  1035. | |  SECTOR  ``| Selects supporting linedefs  
  1036. | |   THING   | Adds a thing                 
  1037. | +---------+---------------------------
  1038. |                  Delete/Merge 
  1039. | +---------+---------------------------
  1040. | |  VERTEX  ``| Vertex-merge (not available yet
  1041. | | LINEDEF   | Creates a new sector         
  1042. | |  SECTOR  ``| Merge or delete sectors      
  1043. | |   THING   | Deletes selected things      
  1044. | +---------+---------------------------
  1045. +
  1046. Editing maps
  1047. ===============
  1048. DRAGGING OBJECTS
  1049. ===============
  1050. To move objects, they must be dragged.  Left-clicking with the mouse picks up the current object for dragging.  When the mouse is clicked again, the object will be dropped.  (Pressing ESC will abort the drag and return the object to its initial position).  
  1051. +
  1052. Editing maps
  1053.  
  1054. ===============
  1055. OBJECT INFO BAR
  1056. ===============
  1057. $B017039/lines
  1058. The object information bar displays data for the current object and allows editing this data.  
  1059. To change a field, press the key associated with that line.  For example, press "7" to change the direction of the current thing object.  Not all fields are editable; the "two-sided" bit for linedefs is handled automatically and cannot be edited.
  1060. +
  1061. editing objects
  1062. Editing maps
  1063.  
  1064. ===============
  1065. EDITING OBJECTS
  1066. ===============
  1067. $B017039/lines
  1068. Objects are edited by modifying values in the object information bar.  Press the key of the line to change to edit any field.  The mouse may be used to select by left-clicking or it may open a help panel for that line by right-clicking.
  1069. +
  1070. object info bar
  1071. Editing maps
  1072.  
  1073. =============
  1074. MOUSE CONTROL
  1075. =============
  1076. Many functions are built into the mouse.
  1077. First-button commands: (object manipulation)
  1078. Tap the first button to pick-up and object for moving.  Tap again to drop the object where it is.
  1079. Hold the first button and move the mouse to use the mouse-pad.
  1080. Hold the first button and tap the second to insert an object.  Different modes use insert differently.
  1081. Second-button commands: (display control)
  1082. Hold the second button and move the mouse to pan across the map.  Panning control is not proportional: at far zooms, the control is less sensitive.
  1083. While holding the second button press and hold the first button.  This enables zooming adjustment.  Push the mouse forward to zoom in and pull back to zoom out.  Be sure to hold the second button first since pressing the first button, then the second is add/split.
  1084. +
  1085. mouse pad
  1086. add/split
  1087.  
  1088. ===============
  1089. CHOOSE AN ANGLE
  1090. ===============
  1091. Select the direction the Thing is to face by moving the mouse cursor relative to the center of this panel.  Click to accept, ESC aborts.
  1092.  
  1093. ==============
  1094. CHOOSE A THING
  1095. ==============
  1096. All of the Thing objects in DOOM are displayed on this panel.  Choose by clicking the mouse on the desired type or press ESC to abort.
  1097.  
  1098. ===================
  1099. CHOOSE SECTOR STYLE
  1100. ===================
  1101. Any of the styles in the sector styles file may be chosen from this panel.
  1102. +
  1103. edit sector styles
  1104.  
  1105. ==================
  1106. CHOOSE SECTOR TYPE
  1107. ==================
  1108. Each sector may have one of several special properties, as displayed on this panel.  Flickering lights and damaging floors are examples of sector types.
  1109.  
  1110. ================
  1111. CHOOSE AN ACTION
  1112. ================
  1113. LineDefs can trigger sectors to perform actions, such as raising a ceiling (door), lowering a floor (lift), or even teleporting.
  1114. Actions that are repeatable (marked by an "r") may be triggered more that once, while others may only work a single time.
  1115. Switch-operated actions (marked by a "s") can only be activated by walking in front of the LineDef and pressing the USE key (as when opening doors).  Most other actions are triggered by walking over the LineDef (and a couple must be shot).
  1116. Almost all actions must be tagged to a Sector (mark the line, press F7, click on the sector).  Some actions, however, do not need a trigger number.  "MDoor"/manual doors (except for the shoot-to-open MDoor #46), exits and scrolling walls do not need to be tagged.
  1117.  
  1118. ===================
  1119. CHOOSE WALL TEXTURE
  1120. ===================
  1121. All of the wall textures in DOOM are displayed and may be chosen from this panel.
  1122. The desired texture may be chosen by either clicking texture name on the panel or by using the viewer.
  1123. To activate the viewer press F10.  There should be 90k free memory for the viewer to load.  Select the displayed wall texture by pressing Enter.
  1124. Pressing ESC from either screen will abort.
  1125. While in the viewer, the texture offsets may be adjusted.
  1126. +
  1127. viewer
  1128. Aligning using the viewer
  1129.  
  1130. ============================
  1131. CHOOSE FLOOR/CEILING TEXTURE
  1132. ============================
  1133. All of the floor (ceiling) textures in DOOM are displayed and may be chosen from this panel.
  1134. The desired texture may be chosen by either clicking texture name on the panel or by using the viewer.
  1135. To activate the viewer press F10.  There should be 90k free memory for the viewer to load.  Select the displayed floor texture by pressing Enter.
  1136. Pressing ESC from either screen will abort.
  1137. +
  1138. viewer
  1139.  
  1140. =============
  1141. SIDEDEF PANEL
  1142. =============
  1143. The SideDef panel displays information about the selected SideDef.  This panel can be used to adjust the X and Y offsets of the textures it uses.  In Addition to the numbers of the associated objects (supporting LineDef, SideDef and facing Sector numbers), this panel also indicates the size of each texture surface.
  1144.  
  1145. ======
  1146. THINGS
  1147. ======
  1148. Thing objects are monsters, players, weapons, ammunition, corpses, pillars, lamps, spikes, etc.; anything that is not part of the walls or floors in DOOM is a Thing object.
  1149. +
  1150. Vertexes
  1151. LineDefs
  1152. Sectors
  1153.  
  1154. ========
  1155. VERTEXES
  1156. ========
  1157. Vertices mark the endpoint of every line on the map.  Move them to alter the shape of the room.
  1158. +
  1159. LineDefs
  1160. Sectors
  1161. Things
  1162.  
  1163. =====
  1164. PWADS
  1165. =====
  1166. PWADs, or "Patch-WADs" are the files DOOM and EdMap use to store map data.  Each PWAD (*.WAD) file may contain several maps and other resources like sound effects and graphics.  PWADs supplement the IWAD ("Internal-WAD"), DOOM.WAD, which contains all the resources necessary for normal game play.  When a PWAD is added, the resources contained in the PWAD update those in the IWAD.  Each time a PWAD is added to the list, some number of resources from the existing list are outdated, sometimes outdating an entire PWAD file. 
  1167. +
  1168. List wads
  1169.  
  1170. ================
  1171. SECTOR IN SECTOR
  1172. ================
  1173. If a sector is created within another sector, note that sector cannot be moved out of its surrounding sector.  Nor can a sector created in the void be moved inside an existing sector.
  1174. Of course, if a sector is created within another, the existing sector must be large enough to surround the new 64x64 sector.
  1175.  
  1176. =============
  1177. DELETE SECTOR
  1178. =============
  1179. Deleting a sector will erase that sector and all objects dependent on it (except Things, which are not associated with sectors).
  1180.  
  1181. =================
  1182. OVERWRITE ON SAVE
  1183. =================
  1184. Overwriting a file will erase all data the file currently holds and replace it with the data to be saved, no matter what the original file contains.
  1185.  
  1186. ===============
  1187. MULTIPLE SELECT
  1188. ===============
  1189. By selecting multiple objects at once allows many objects to be modified at once.  Objects may be added to the multiple select list by pressing Control-Enter or by holding Control down while clicking on the object with the mouse (using the first button).  Press Enter to clear the list or use the mouse pad.
  1190. +
  1191. Mouse pad
  1192.  
  1193. =========================
  1194. ALIGNING USING THE VIEWER
  1195. =========================
  1196. Wall textures may now be aligned while in the texture-viewer.  From the Choose wall texture panel, pressing F10 will activate the viewer.  A box will outline what part of the texture would be seen in DOOM.  While holding down the shift key, arrows will adjust the box along the X and Y offsets.
  1197. +
  1198. Viewer
  1199. SideDef panel
  1200.  
  1201. ================
  1202. DRAGGING OBJECTS
  1203. ================
  1204. While dragging, objects are attached to the mouse and can then be placed by moving the mouse and clicking either button or hitting enter.  Pressing ESC will abort the drag and place the objects in their original positions.
  1205.  
  1206. ================
  1207. CREATING SECTORS
  1208. ================
  1209. To create a new area, like a room or a different part of a room, insert a sector.  While in sectors mode, press insert (or the mouse command) and a new 64x64 sector will appear under the mouse pointer.  Note that this is usually done outside any other sector, when the object information panel shows no sector.
  1210. +
  1211. merging sectors
  1212. sectors
  1213.  
  1214. ===============
  1215. MERGING SECTORS
  1216. ===============
  1217. Sectors are merged when they share a LineDef.  To make two sectors merge, a line from one must be moved ontop of a line from the other so that the vertices connect.  When both pairs of vertices fuse together, the two lines will merge into one two-sided linedef marking the boundary of both sectors.
  1218. +
  1219. sectors
  1220.  
  1221. ===================
  1222. DISPLAY ARRANGEMENT
  1223. ===================
  1224. $B000039xxxyyyWhile in normal view, EdMap displays information to the left while the rest of the screen shows the map.  The top half of this is the main menu.  Below the menu is a small square for general information (filename, memory, position, etc.) and a mode bar highlighting the current mode.  The bottom half is the object information bar.  This provides data about the currently marked object.
  1225. If the screen is set to full-view, all information to the left is removed, leaving the entire screen to display the map.  The menu can still be used in this mode with the keyboard.
  1226. To switch between normal and full screen, either use the hotkey: Ctrl-S, the menus: press "D" (Display) and "F" (Full screen), or the mouse pad.
  1227. +
  1228. Menu
  1229. Mouse pad
  1230. Mouse areas
  1231.  
  1232. =========
  1233. MOUSE AREAS
  1234. =========
  1235. $B000040xxxyyy
  1236. Right-clicking anywhere in the left bar will open a help panel for that topic.  Left-clicking activates an area.
  1237. Left-clicking in the menu expands that selection, and clicking in the object-information bar selects a field.
  1238. +
  1239. Mouse areas, page 2
  1240. Display arrangement
  1241. =====
  1242. Mouse areas, page 2
  1243. =====
  1244. $B002122090141
  1245. Left-clicking here in this information box will quick-save the PWAD (if it there are changes to save).
  1246. +
  1247. Mouse areas, page 3
  1248. Display arrangement
  1249. =====
  1250. Mouse areas, page 3
  1251. =====
  1252. $B002143090152
  1253. Left-clicking here will open the System information panel ("I"nfo "S"ystem resources).
  1254. +
  1255. Mouse areas, page 4
  1256. Display arrangement
  1257. =====
  1258. Mouse areas, page 4
  1259. =====
  1260. $B002174090200
  1261. Clicking here will open the Grid/snap sizes panel, to adjust the size of the dot grid or the snap grid.
  1262. +
  1263. Mouse areas, page 5
  1264. Display arrangement
  1265. =====
  1266. Mouse areas, page 5
  1267. =====
  1268. $B002215090226
  1269. Left-clicking here, in the object information panel, will open the "Goto.." panel to zoom to a specified object.
  1270. +
  1271. Display arrangement
  1272. =========
  1273. MOUSE PAD
  1274. =========
  1275. The mouse pad in EdMap is a tiny menu that appears under the mouse pointer which can be used to quickly change modes and clear the multiple-selection list without using the keyboard.  While holding the first mouse button, move the mouse slightly to bring up the pad.  Release the button to select.  To use LineDef mode, for example, hold the first button and slide the mouse to left and release.
  1276. +
  1277. Mouse control
  1278. Multiple select
  1279.  
  1280. =============
  1281. OBJECT BASICS
  1282. =============
  1283. Objects are the basic components of maps; vertices, linedefs (walls), sectors and things are all objects.  Vertices are the points on the map that all other structures are built from.  Each LineDef connects two vertices together.  Sectors are usable areas on the map, bordered by LineDefs.  Everything happens within sectors; no players or monsters should exist outside sectors in the void.  Things are actual objects in the game; monsters, weapons and player starts are all things.
  1284. +
  1285. UDS [4-5] VERTEXES
  1286. Vertexes
  1287. UDS [4-3] LINEDEFS
  1288. Linedefs
  1289. UDS [4-9] SECTORS
  1290. Sectors
  1291. UDS [4-2] THINGS
  1292. Things
  1293. editing objects
  1294. Editing maps
  1295.  
  1296. ===
  1297. VERTEX INFO BAR
  1298. ===
  1299. $B017039/lines
  1300. The vertex information bar provides information related to the current vertex.  X and Y coordinates and supported linedef data is provided.
  1301. +
  1302. VX: X,Y
  1303. VX: supported linedefs
  1304. VX: linedef length
  1305. UDS [4-5] VERTEXES
  1306.  
  1307.  
  1308. ===
  1309. VX: X,Y
  1310. ===
  1311. $B019021/lines
  1312. These two fields (1 and 2) are not editable via the vertex information bar.  To change the position of any point, that point or an object supported by it must be dragged.
  1313. +
  1314. Vertex info bar
  1315. UDS [4-5] VERTEXES
  1316.  
  1317. ===
  1318. VX: supported linedefs
  1319. ===
  1320. $B014280084344
  1321. This diagram indicates the linedefs supported by the current vertex.  Also shown are the direction and reference keys to those linedefs.  To edit the length of one of these linedefs, press its respective key (also the field of the vertex info bar).
  1322. +
  1323. Vertex info bar
  1324. UDS [4-5] VERTEXES
  1325.  
  1326. ===
  1327. VX: linedef length
  1328. ===
  1329. $B030039/lines
  1330. To specify the length of any linedef supported by the current vertex, edit the field on which that linedef appears on the vertex info bar (this key is also used in the supporting linedefs diagram).  The position of the current vertex will adjust (by moving toward or away from the other vertex supporting that linedef) to best match the specified length.  The actual length may be off by half a unit because vertices are based on ordinal coordinates.
  1331. +
  1332. Vertex info bar
  1333.  
  1334. ===
  1335. LINEDEF INFO BAR
  1336. ===
  1337. $B017039/lines
  1338. The linedef information bar displays data specific to the current linedef and both (if they exist) supported sidedefs.
  1339. The first 9 lines toggle the attributes of the linedef (bit 3 is handled automatically).  Line 0 specifies the linedef trigger and type (action).  Field B displays the length of the linedef.  To specify a new length, mark either of the supporting vertices and edit the length via the vertex info bar.  Lines G through P represent both sidedefs (lines after K are blank if there is no second sidedef).  Q flips the linedef by swapping the vertex references.
  1340. +
  1341. UDS [4-3] LINEDEFS
  1342.  
  1343. ====
  1344. LD: Block all
  1345. ====
  1346. $B019020/lines
  1347. This bit prevents players and monsters from crossing the linedef.  This does not block bullets or projectiles.
  1348. +
  1349. Linedef info bar
  1350. /
  1351. UDS [4-3-1] LINEDEF flags
  1352.  
  1353. ====
  1354. LD: block enemy
  1355. ====
  1356. $B020021/lines
  1357. Prevents monsters from crossing.  Does not affect players, bullets or projectiles.
  1358. +
  1359. Linedef info bar
  1360. /
  1361. UDS [4-3-1] LINEDEF flags
  1362. ====
  1363. LD: two-sided
  1364. ====
  1365. $B021022/lines
  1366. This bit is handled automatically.  It determines whether the linedef is two-sided (bordering two sectors) or one-sided (bordering void).  This bit may only be toggled in Pro-Mode.
  1367. +
  1368. Linedef info bar
  1369. Programs
  1370. UDS [4-3-1] LINEDEF flags
  1371. ====
  1372. LD: upper pegged
  1373. ====
  1374. $B022023/lines
  1375. If on, the textures on this linedef are "pegged" to their upper bounds.  If the ceiling rises, these adjacent textures will scroll up with the ceiling.
  1376. +
  1377. Linedef info bar
  1378. LD: lower pegged
  1379. UDS [4-3-1] LINEDEF flags
  1380. ====
  1381. LD: lower pegged
  1382. ====
  1383. $B023024/lines
  1384. Textures are "pegged" to their lower bounds if this bit is on.  If the floor drops, lower pegged textures around the floor will scroll down.
  1385. +
  1386. Linedef info bar
  1387. LD: upper pegged
  1388. UDS [4-3-1] LINEDEF flags
  1389. ====
  1390. LD: Secret wall
  1391. ====
  1392. $B024025/lines
  1393. Normally solid walls (one-sided linedefs) are not displayed the same as two-sided linedefs on  the automap.  This bit will "hide" areas by drawing these linedefs the same as one-sided linedefs.
  1394. This bit has no relation to the "secret" score at the end of the level.
  1395. +
  1396. Linedef info bar
  1397. /
  1398. UDS [4-3-1] LINEDEF flags
  1399. ====
  1400. LD: block sound
  1401. ====
  1402. $B025026/lines
  1403. Sound normally passes from sector to sector if they share a linedef and the passage is natural (not from a sector whose ceiling is lower than the floor of another).  This bit prevents sounds from crossing the linedef.
  1404. +
  1405. Linedef info bar
  1406. /
  1407. UDS [4-3-1] LINEDEF flags
  1408. ====
  1409. LD: Never map
  1410. ====
  1411. $B026027/lines
  1412. Linedefs normally appear on the automap when any texture on the linedef is seen or when the "computer map" is picked up.  A linedef whose Never map bit is set will never appear normally on the automap.
  1413. +
  1414. Linedef info bar
  1415. LD: Start on map
  1416. UDS [4-3-1] LINEDEF flags
  1417. ====
  1418. LD: Start on map
  1419. ====
  1420. $B027028/lines
  1421. Any linedef with this bit set will always appear on the automap.
  1422. +
  1423. Linedef info bar
  1424. LD: Never map
  1425. UDS [4-3-1] LINEDEF flags
  1426. ====
  1427. LD: action
  1428. ====
  1429. $B028029/lines
  1430. If a linedef triggers an action, it is specified on this line.  Press F7 to select an action and tag a sector.  Press 0 alone to change the linedef type (action).
  1431. +
  1432. Linedef info bar
  1433. /
  1434. UDS [4-3-2] LINEDEF types
  1435. ====
  1436. LD: length
  1437. ====
  1438. $B029030/lines
  1439. The length field (line B) is not editable.  Use the vertex info bar to specify a new length for a linedef. 
  1440. +
  1441. Linedef info bar
  1442. Vertex info bar
  1443. VX: linedef length
  1444.  
  1445. ====
  1446. LD: sidedef panel
  1447. ====
  1448. $B030038/lines
  1449. Lines G and L of the linedef info bar display sidedef information and, if pressed, will open the sidedef panel for those objects.
  1450. First on the line is the sidedef number, then the X and Y texture offsets for aligning the bitmapped textures along that linedef.
  1451. +
  1452. Linedef info bar
  1453. /
  1454. UDS [4-4] SIDEDEFS
  1455. ====
  1456. LD: above texture
  1457. ====
  1458. $B031038/lines
  1459. The "Above" (or upper) texture on a sidedef, if it exists, is the texture between the facing ceiling and the lower ceiling of the other side.  A one-sided linedef does not use above or below textures.  This texture follows the same rules as a texture on a one-sided linedef: no transparent textures.
  1460. +
  1461. Linedef info bar
  1462. LD: main texture
  1463. LD: below texture
  1464. /
  1465. UDS [4-4] SIDEDEFS
  1466. ====
  1467. LD: main texture
  1468. ====
  1469. $B031038/lines
  1470. The Main texture on a sidedef is the texture between the lowest ceiling and the highest floor.  
  1471. All one-sided linedefs must have a main texture.  Transparent textures are not allowed.
  1472. On a two-sided linedef, this texture not required.  If specified, however, this texture may not be a multi-patch texture.  
  1473. +
  1474. Linedef info bar
  1475. LD: above texture
  1476. LD: below texture
  1477. /
  1478. UDS [4-4] SIDEDEFS
  1479. ====
  1480. LD: below texture
  1481. ====
  1482. $B031038/lines
  1483. The "Below" (or lower) texture on a sidedef, if it exists, is the texture between the facing ceiling and the lower ceiling of the other side.  A one-sided linedef does not use above or below textures.  This texture follows the same rule as a texture on a one-sided linedef: no transparent textures.
  1484. +
  1485. Linedef info bar
  1486. LD: above texture
  1487. LD: main texture
  1488. /
  1489. UDS [4-4] SIDEDEFS
  1490. ====
  1491. LD: flip
  1492. ====
  1493. $B038039/lines
  1494. Linedefs may be "flipped" by pressing "Q" while in linedef mode.  
  1495. +
  1496. Linedef info bar
  1497.  
  1498. ====
  1499. SECTOR INFO BAR
  1500. ====
  1501. $B017039/lines
  1502. Current sector and style data is provided in the sector information bar.
  1503. UDS [4-9] SECTORS
  1504. ====
  1505. SE: ceiling height
  1506. ====
  1507. $B019020/lines
  1508. Specifies how high the ceiling is in a given sector.
  1509. +
  1510. Sector info bar
  1511. SE: ceiling texture
  1512. SE: floor height
  1513. UDS [4-9] SECTORS
  1514. ====
  1515. SE: ceiling texture
  1516. ====
  1517. $B020021/lines
  1518. The texture used on the ceiling.  Ceiling and floor textures are chosen from the same list.
  1519. +
  1520. Sector info bar
  1521. SE: ceiling height
  1522. SE: floor texture
  1523. UDS [4-9] SECTORS
  1524. ====
  1525. SE: floor height
  1526. ====
  1527. $B021022/lines
  1528. How high the floor of that sector is.
  1529. +
  1530. Sector info bar
  1531. SE: floor texture
  1532. SE: ceiling height
  1533. UDS [4-9] SECTORS
  1534. ====
  1535. SE: floor texture
  1536. ====
  1537. $B022023/lines
  1538. The texture on the floor of a given sector.  Ceiling and floor textures are chosen from the same list.
  1539. +
  1540. Sector info bar
  1541. SE: floor height
  1542. SE: ceiling texture
  1543. UDS [4-9] SECTORS
  1544. ====
  1545. SE: light value
  1546. ====
  1547. $B023024/lines
  1548. Specifies how bright the current sector is.  Valid values are from 0 (no light) to 255 (max brightness).
  1549. Just as 0 makes a room notably dark, 255 should not be used for normal sectors.  Often 255 is reserved for outdoor areas (where the sky texture is F_SKY).
  1550. +
  1551. Sector info bar
  1552. UDS [4-9] SECTORS
  1553. ====
  1554. SE: sector type
  1555. ====
  1556. $B024025/lines
  1557. Sectors may have special characteristics (such as flickering light or damaging areas).  This field (line 6 of the sector info bar) specifies the sector type.
  1558. This is unrelated to linedef types (actions).
  1559. +
  1560. Sector info bar
  1561. UDS [4-9-1] special SECTOR types
  1562. ====
  1563. SE: trigger
  1564. ====
  1565. $B025026/lines
  1566. Linedef actions trigger specific sectors by tag numbers.  This line (7) displays the tag number of the current sector and any actions it performs.  To have a linedef trigger more than one sector, either edit this line (press 7) and enter the new tag number, or press F7 and mark the sector already tagged to the triggering linedef.  (This also works for multiple-selected sectors; multiple all the sectors to act on a given linedef, press F7, and tag the originally tagged sector.)
  1567. +
  1568. Sector info bar
  1569. UDS [4-9] SECTORS
  1570. ====
  1571. SE: styles
  1572. ====
  1573. $B026034/lines
  1574. To facilitate map creation, sector styles keep commonly used sector data, which is available via line 8 (or 9) of the sector info bar.  Whenever a new sector is created, the current style is used as a reference.
  1575. +
  1576. Sector info bar
  1577. SE: editing the style
  1578. Sectors
  1579.  
  1580. ====
  1581. SE: editing the style
  1582. ====
  1583. $B028034/lines
  1584. Just as the current object may be edited using the info bar, so may the current sector style.  Lines 0 through J mimic lines 1 through 5 of the current sector.  Line K specifies the wall texture of new sectors.
  1585. +
  1586. Sector info bar
  1587. SE: styles
  1588.  
  1589. ====
  1590. SE: progression
  1591. ====
  1592. $B034039/lines
  1593. The five progression values (lines L through Q) of the sector information bar adjust the current sector style each time a new sector is created.  If line O (light) is set to -20 and P (map x) is set to 80, for example, and five sectors are created, each sector will be made 80 units to the right and 20 units darker than its predecessor.
  1594. +
  1595. Sector info bar
  1596.  
  1597. ====
  1598. THING INFO BAR
  1599. ====
  1600. $B017039/lines
  1601. Current thing-object data is shown in the thing information bar.
  1602. +
  1603. TH: view attributes
  1604. UDS [4-2] THINGS
  1605. ====
  1606. TH: thing type
  1607. ====
  1608. $B019024/lines
  1609. The type of thing may be edited by pressing 1 while in things mode.
  1610. +
  1611. Thing info bar
  1612. UDS [4-2-1] THING types
  1613. ====
  1614. TH: angle
  1615. ====
  1616. $B024025/lines
  1617. Some objects (monsters, player starts, teleporter destinations) are directional.  Line 6 specifies the direction the current thing-object faces.
  1618. +
  1619. Thing info bar
  1620. UDS [4-2] THINGS
  1621. ====
  1622. TH: skill
  1623. ====
  1624. $B025028/lines
  1625. Different things appear in different levels of difficulty (Hurt me plenty, Ultra-violence).  These lines specify which skills the current object appears in.
  1626. +
  1627. Thing info bar
  1628. TH: multi only
  1629. UDS [4-2-3] THING options
  1630. ====
  1631. TH: deaf guard
  1632. ====
  1633. $B028029/lines
  1634. Monsters may be "deaf guards."  Normally an enemy will attack when it sees or hears a player.  If this bit is set, the current monster will only attack if it sees a player.
  1635. +
  1636. Thing info bar
  1637. UDS [4-2-3] THING options
  1638. ====
  1639. TH: multi only
  1640. ====
  1641. $B029030/lines
  1642. Just as some thing-objects appear only in some skill levels, this bit reserves things for multiplayer games.
  1643. +
  1644. Thing info bar
  1645. TH: skill
  1646. UDS [4-2-3] THING options
  1647. ====
  1648. TH: radius
  1649. ====
  1650. $B030031/lines
  1651. This field is not editable.  Shown is the radius of the current thing-object.
  1652. This value is taken from the active THINGS.TXT file.
  1653. +
  1654. Thing info bar
  1655. TH: height
  1656. UDS [4-2-2] THING sizes
  1657. ====
  1658. TH: height
  1659. ====
  1660. $B031032/lines
  1661. Height of the current thing-object.  Like the radius field, this line is not editable.  
  1662. This value is taken from the active THINGS.TXT file.
  1663. +
  1664. Thing info bar
  1665. TH: radius
  1666. UDS [4-2-2] THING sizes
  1667. ====
  1668. TH: view
  1669. ====
  1670. $B032033/lines
  1671. This line toggles between view Any and view Equal.  Filters what thing-objects are shown on the screen.
  1672. If "view Any," an object is shown if the view attributes (lines L through Q) ANDed with a the attributes of a given thing produce a non-zero result.
  1673. If "view Equal," the view attributes are XORed, and zero-producing things are displayed.
  1674. +
  1675. Thing info bar
  1676. TH: view attributes
  1677.  
  1678. ====
  1679. TH: circle
  1680. ====
  1681. $B033034/lines
  1682. Specifies which things to draw radius circles around.
  1683. +
  1684. Thing info bar
  1685.  
  1686. ====
  1687. TH: view attributes
  1688. ====
  1689. $B034039/lines
  1690. These five bits (lines L to Q) filter which things are shown on the screen.  See TH: view for more info.
  1691. +
  1692. Thing info bar
  1693. TH: view
  1694.  
  1695. =====
  1696. HINTS, TIPS & TRICKS
  1697. =====
  1698. Scroll-Lock suspends child-processes.  If on when loading EDMAPCFG, BUILD.BAT or during play-map, the process may be run as normal (Shell), skipped (Return) or the parent process may quit (Abort).
  1699. If caught in a loop, where the parent process repeatedly fails to run the child process, holding Control, Alternate, and both shifts while Scroll-Lock is on will abort to DOS.
  1700.  
  1701. ====
  1702. /DEBUG
  1703. ====
  1704. /DEBUG specifies debugging mode.  If compiled for testing (as noted in the About panel), this enables the more test routines.  In debugging mode, Scroll-Lock will pause initiating the graphics screen.
  1705.  
  1706. =====================
  1707. UNOFFICIAL DOOM SPECS
  1708. =====================
  1709. $C
  1710.  
  1711.  
  1712.  
  1713.  
  1714. $CThe Unofficial DOOM Specs  (`U`D`S`)
  1715.  
  1716.  
  1717.  
  1718. $CRelease v1.666 - December 15th, 1994
  1719. $CWritten by: Matthew S Fell (msfell@aol.com)
  1720.  
  1721. $u
  1722. This article (Unofficial DOOM Specs "UDS") is Copyright 1994 by Matt Fell.  All rights reserved.  All help-topics prefixed with "UDS" are written by Matt Fell, not Jeff Rabenhorst, author of EdMap.  See the original file for more information.
  1723. +
  1724. UDS, Contents
  1725. UDS, Disclaimer
  1726.  
  1727. ===============
  1728. UDS, DISCLAIMER
  1729. ===============
  1730. These specs are to aid in informing the public about the games DOOM and DOOM 2, by id Software.  In no way should this promote your killing yourself, killing others, or killing in any other fashion. Additionally, the author does not claim ANY responsibility regarding ANY illegal activity concerning this file, or indirectly related to this file.  The information contained in this file only reflects id Software indirectly, and questioning id Software regarding any information in this file is not recommended.
  1731. +
  1732. Unofficial DOOM Specs
  1733. UDS, Contents
  1734.  
  1735. =============
  1736. UDS, CONTENTS
  1737. =============
  1738. +
  1739. UDS [1] Introduction
  1740. /
  1741. UDS [2] The Basics
  1742. /
  1743. UDS [3] List of DOOM.WAD Directory Entries
  1744. /
  1745. UDS [4] The Levels
  1746. /
  1747. UDS [5] Graphics
  1748. /
  1749. UDS [6] Flats (Floor and Ceiling Textures)
  1750. /
  1751. UDS [7] Sounds and Music
  1752. /
  1753. UDS [8] Miscellaneous Lumps
  1754. /
  1755. UDS [9] Savegame Files
  1756. /
  1757. UDS [10] The DOOM.EXE File
  1758. /
  1759. UDS, APPENDICES
  1760.  
  1761. =============
  1762. UDS [1] Introduction
  1763. =============
  1764. DOOM is simply an all-time great game. A big factor in its success and durability is the plethora of user-created add-ons. id Software tacitly encouraged them by including the -FILE parameter, and by having a data format that is both straightforward and easy to understand. DOOM is basically two files, DOOM.EXE and DOOM.WAD. DOOM.EXE is the "engine" which does the display and controls the game, and DOOM.WAD has ALL of the graphics, sound, and map/level data that the engine uses. The -FILE parameter allows small or large external "WAD" files to be incorporated, changing any number of those graphics, sounds, and maps.
  1765. DOOM 2 has many things in common with DOOM. It uses the same EXE file as version 1.666 of DOOM, and the WAD file format is the same. It's just the contents of the WAD file that are different; there are more enemies! more pictures! more weapons! more stuff!!
  1766. This document explains in great detail nearly all aspects of the doom WAD file format. And a new chapter (10) documents the location of data within DOOM.EXE itself, so that various unusual game-play changes can be made. This information has been updated to apply to DOOM 2 as well as DOOM 1.
  1767. The specs were originally conceived as an aid to programmers making DOOM utilities, especially map-editors. Coincidentally, there might also be information useful to advanced level designers and players.
  1768. The material herein is somewhat technical and it is not recommended for beginners, unless they are determined. There are some other very useful documents in existence; I list the ones I know of in Appendix [A-3].
  1769. +
  1770. UDS [1-1] id Software's Copyright
  1771. /
  1772. UDS [1-2] What's New
  1773. /
  1774. =============
  1775. UDS [1-1] id Software's Copyright
  1776. =============
  1777. My comments and statements are by no means official, and the excerpts below are just the parts that I think are relevant to these specs. Please read the LICENSE.DOC and README.EXE that came with DOOM.
  1778.  
  1779. $tThe LICENSE.DOC says:
  1780. $u$T$I"You shall not:  rent, lease, sell, distribute for money or other consideration, modify, translate, disassemble, decompile, reverse engineer, or create derivative works based upon the Software.
  1781. Notwithstanding the foregoing, you may create a map editor, modify maps and make your own maps (collectively referenced as the "Permitted Derivative Works") for the Software.  You may not sell or distribute any Permitted Derivative Works but you may exchange the Permitted Derivative Works at no charge amongst other end-users.
  1782. In order to commercially distribute any such map editor or data utility you must first sign ID's Data Utility License and ID reserves the right to deny authorization to commercial distribute the any such map editor or data utility.  You may request a copy of the Data Editor License from ID"
  1783. "(except for backup purposes) You may not otherwise reproduce, copy or disclose to others, in whole or in any part, the Software."
  1784.  
  1785. $U$tThe README says:
  1786. $u$T$I"id Software respectfully requests that you do not modify the levels for the shareware version of DOOM.  We feel that the distribution of new levels that work with the shareware version of DOOM will lessen a potential user's incentive to purchase the registered version.
  1787. "If you would like to work with modified levels of DOOM, we encourage you to purchase the registered version of the game."
  1788. If you are making add-ons, plan on them not working on the shareware game, and plan on including statements about the trademarks and copyrights that id Software owns, as well as disclaimers that they won't support your add-on product, nor will they support DOOM after it has been modified.
  1789. +
  1790. UDS, Contents
  1791. =
  1792. UDS [1-2] What's New
  1793. =
  1794. Each new version of these specs renders the previous version obsolete.  This document has grown considerably in size, and to fight that trend, I'll not discuss it any more.  It has now been five months since the specs were updated. I won't talk about that either. I'll just apologize for not releasing updates in late May and July like I should have. Those updates would have been numbered 1.4 and 1.5, so perhaps that's why this is version 1.666.
  1795. Here's some of the new or revised sections since the 1.3 specs:
  1796. $u    - DOOM 2 info, especially in [4-2-1] and [4-3-2]
  1797.     - lots of info on the DOOM.EXE file in [10]
  1798.     - BNF style definitions in [A-1]
  1799.     - DOOM engine limits in [A-2]
  1800.     - the DEMO format [8-6]
  1801.     - the ENDOOM lump [8-3]
  1802.     - comprehensive list of WAD lumps in [3]
  1803.     - many parts rewritten for clarity
  1804.     - changes in terminology to reflect id's where possible, and to be more consistent throughout
  1805.     - reformatted again, errors and typos corrected
  1806. +
  1807. UDS, Contents
  1808. =============
  1809. UDS [2] The Basics
  1810. =============
  1811. The starting point is the concept of "WAD". It is not an acronym, it just means a collection of data. Throughout this document, "WAD" or "wad" will mean a file with a .WAD extension that contains data for the doom engine to use.
  1812.  
  1813. $tA$u WAD file has three parts:
  1814. $T(1) a twelve-byte header
  1815. (2) one or more "lumps"
  1816. (3) a directory or "info table" that contains the names, offsets, and sizes of all the lumps in the WAD
  1817. $tThe header consists of three four-byte parts:
  1818.  
  1819. $T(a) an ASCII string which must be either "IWAD" or "PWAD"
  1820. (b) a 4-byte (long) integer which is the number of lumps in the wad
  1821. (c) a long integer which is the file offset to the start of the directory
  1822. $tThe directory has one 16-byte entry for every lump. Each entry consists of three parts:
  1823.  
  1824. $T(a) a long integer, the file offset to the start of the lump
  1825. (b) a long integer, the size of the lump in bytes
  1826. (c) an 8-byte ASCII string, the name of the lump, padded with zeros.  For example, the "DEMO1" entry in hexadecimal would be (44 45 4D 4F 31 00 00 00)
  1827. $U
  1828. A "lump" is just data, in one of several different formats. Some contain sound data, some contain graphics data, some contain level structure data, etc. These specs are mostly concerned with delineating the formats of the various lump types. There are 10 different types of map/level lump formats, each has a section in chapter [4] (sections 2-11).  There are 13 other types of lump formats, listed below with the section where the format is explained, and the actual lump names in parentheses.  Also, Appendix [A-1] has definitions of the structures of all these WAD elements.
  1829. $u  [8-1] palettes (PLAYPAL)
  1830.   [8-2] colormaps (COLORMAP)
  1831.   [8-3] dos exit text (ENDOOM)
  1832.   [8-6] demos (DEMO1, DEMO2, and DEMO3)
  1833.   [8-4] texture composition list (TEXTURE1 and TEXTURE2)
  1834.   [8-5] wall patch "number for name" indexing list (PNAMES)
  1835.   [7-4] midi mapping (GENMIDI)
  1836.   [7-5] Gravis UltraSound patch mappings (DMXGUS)
  1837.   [7-1] PC speaker sound effects (DP*)
  1838.   [7-2] Soundcard sound effects (DS*)
  1839.   [7-3] songs (D_*)
  1840.   [6]   flats (lumpnames between F_START and F_END)
  1841.   [5]   all other graphics (all other lumps)
  1842. $U
  1843. The "marker" and "label" lump names like "S_START" and "E1M1" (or "MAP01") do not actually refer to lumps - they have zero length. They merely serve to mark the beginning or end of a set of related lumps.
  1844. It is possible to include other directory entries and lumps in a wad file, e.g. an entry called CLOWNS could point to a lump that includes the level creator's name, date of completion, and the latitude and longitude of the Holy Grail. None of these non-standard entries will be used by DOOM, nor will they cause it problems.
  1845. +
  1846. UDS [2-1] PWADs
  1847. /
  1848. UDS [2-2] DOOM version information
  1849. /
  1850. UDS [2-3] Terminology conventions
  1851. /
  1852. ================
  1853. UDS [2-1] PWADS
  1854. ================
  1855. There are two types of wad files. The original DOOM.WAD and DOOM2.WAD files are "IWAD"s, or "Internal wads", meaning they contain all of the data necessary to play. The other type is the "PWAD" file, "Patch wad", an external file which has the same structure, but with far fewer entries in the directory. The data in a pwad is substituted for the original data in the DOOM.WAD, thus allowing for much easier distribution of new levels. Only those resources listed in the pwad's directory are changed, everything else is loaded from the IWAD. All external wads should have the "PWAD" indicator, as id has requested.
  1856. A typical pwad might contain new data for a single level, in which case it would contain the 10 lumps and 11 directory entries necessary to define the level (as described in chapter [4]).
  1857. A pwad file may contain more than one level or parts of levels, in addition to replacement graphics, sounds, etc. (as of version 1.666, sprites and flats do NOT work from pwads - see chapter [5] for more). In fact, there is apparently no limit to how many entries may be in a pwad. The original doom levels are pretty complicated, and they are from 50-200 kilobytes each in size, uncompressed.
  1858. Pwad files need to have the extension .WAD to work. Many of them have descriptive names, e.g. if J.R.R. Tolkien made a new level, he might call it GONDOLIN.WAD - to use this level, a player would type
  1859. DOOM -FILE GONDOLIN.WAD 
  1860. at the command line, along with any other parameters. More than one external file can be added, thus in general:
  1861. DOOM -FILE [pwad_filename] [pwad_filename] [pwad_filename] ...
  1862. If there are duplicate entries amongst the directories of all the wads being "added", the pwads listed LAST take precedence.
  1863. When the game loads, a "modified game" message will appear if there are any pwads involved, reminding the player that id Software will not give technical support or answer questions regarding modified levels.
  1864. With DOOM version 1.666, there is also the @responsefile option for listing command line parameters and -file specifications. See the DOOM README or the latest FAQ for more information. Also, there are numerous "front-end" utilities that make it easier to play pwads, e.g. load several external files at once, warp to certain levels, specify options, etc.
  1865. +
  1866. UDS, Contents
  1867. =
  1868. UDS [2-2] DOOM version information
  1869. =
  1870. $u$t$I$L1.0$p     10dec93 01:00 $P first release (aka DOOM Operating System 0.99)
  1871. 1.1$p     16dec93 01:10 $P slightly different from 1.0, newer dos extender
  1872. 1.2$p     17feb94 01:20 $P modem play added!
  1873. 1.3$p     -       -     $P unauthorized beta release
  1874. 1.4$p     28jun94 01:04 $P shareware beta
  1875. 1.5$p     ??jul94 ?     $P shareware beta
  1876. 1.6$p     03aug94 01:06 $P shareware beta
  1877. 1.6$p66   01sep94 16:42 $P registered full upgrade!
  1878. 1.6$p66   ?       ?     $P DOOM 2!
  1879.  
  1880. $0The important releases as of this writing are 1.2 and 1.666. Hopefully, everyone will move up to 1.666 soon; it has many important improvements over 1.2. The 1.4, 1.5, and 1.6 shareware betas contained increasing amounts of the stuff that's now in 1.666, but there's no information here about what exactly those changes were. One, I didn't keep track, and two, they're not really important.
  1881. See appendix [A-3] for some miscellany about what has changed from version to version.
  1882. +
  1883. UDS, Contents
  1884. =
  1885. UDS [2-3] Terminology conventions
  1886. =
  1887. Throughout this document, I will use the following conventions for numbers and variable types:$u
  1888.  
  1889. $I$t(1) Most numbers will be decimal. Hexadecimal numbers will usually be labeled thus: 0xffff or $ffff. But sometimes I'll say "hex ...".  And in tablature form, a column heading "HEX" indicates all the numbers in that column are hexadecimal.
  1890. (2) "byte" is of course the generic, 8 bits. It will usually mean one 8-bit component of a larger data type, or an 8-bit ASCII character, or some such. As a number, it is an unsigned 8-bit integer (0..255).
  1891. (3) "short" is a signed 16-bit integer (-32768..32767), stored in lo-hi format.
  1892. (4) "ushort" or "unsigned short" is an unsigned 16-bit integer (0..65535).
  1893. (5) "integer" or "long" is a signed 32-bit integer. If you don't read this first, my use of the word "integer" might not be immediately apparent.
  1894. (6) "string8" or "8-byte string" is an ASCII string with length between 1 and 8 characters inclusive. If its length is less than 8, the remaining bytes are zeros.
  1895. (7) The first byte of a file or any data structure, for addressing and offset purposes, is byte #0, not byte #1.
  1896. (8) Some abbreviations I use: E1, E2, and E3 refer to episodes 1, 2, and 3 respectively. "The EXE" means the file DOOM.EXE.
  1897. (666) Any reference to this number is purely intentional.
  1898. +
  1899. UDS, Contents
  1900. =
  1901. UDS [3] List of DOOM.WAD Directory Entries
  1902. =
  1903. There are over 2000 entries in the DOOM.WAD directory. Most of them can be easily described in groups, and so are not explicitly mentioned in this list. This includes the sprites (see [4-2-1] for sprite names and [5] for the sprite lump naming system), the wall patches ([8-4] and [8-5] have more info), the flats (chapter [6]), the sounds and songs (chapter [7]), and the map data lumps (chapter [4]). All the others are listed here.
  1904. There have been several changes from version to version. The "Ver" column indicates in which doom versions the lump exists:
  1905. $u$t$I___     no indication means it is in every version. Most are like this.
  1906. 1.1     it was in 1.0 and 1.1, but not in 1.2 and later. It is obsolete.
  1907. 1.2     it is not in 1.1 and earlier, only in 1.2 and up.
  1908. 1.6     it is not in 1.2 and earlier, only in 1.666 and up.
  1909. r       it is only in the registered version, not the shareware.
  1910. 1       it is only in DOOM 1, it is not in DOOM 2.
  1911. 2       it is only in DOOM 2, it is not in DOOM 1.
  1912.  
  1913. $UIn the lump names, x (and y and e) indicates variable ASCII characters, and * can be replaced by an ASCII string (up to the 8-byte lumpname limit).
  1914. $t$I$L$u
  1915. $pLumpName  Ver   $PDescription
  1916. $p--------  ---   -----------
  1917. $pPLAYPAL         $Pfourteen 256 color palettes. See [8-1].
  1918. $pCOLORMAP        $Pmaps colors in the palette down to darker ones. [8-2].
  1919. $pENDOOM          $Ptext message displayed when you exit to DOS. [8-3].
  1920. $pDEMOx           $Px=1-3, are the demos. [8-6].
  1921. $pExMy            $Psubsequent entries define a single level's data. [4].
  1922. $pMAPxy     2     $Plike ExMy, but for DOOM 2.
  1923. $pTEXTURE1        $Plist of wall texture names and their composition data, used in the SIDEDEF portion of each level. [8-4].
  1924. $pTEXTURE2  r     $Pmore wall texture compositions.
  1925. $pPNAMES          $Plists all lump names used as wall patches. [8-5].
  1926. $pGENMIDI         $PGeneral Midi standard instrument data. [7-3].
  1927. $pDMXGUS          $PGravis Ultra Sound instrument patches. [7-4].
  1928.  
  1929. $pD_ExMy          $Pmusic for a doom 1 level. [7-2].
  1930. $pD_INTER         $Pmusic played on the summary screen between levels.
  1931. $pD_INTRO         $Pmusic played when the game starts.
  1932. $pD_INTROA  1.2   $Pmore introductory music.
  1933. $pD_VICTOR        $Pmusic played on the victory text-screen after an episode.
  1934. $pD_BUNNY   r     $Pmusic for while a certain rabbit has his story told...
  1935. $pD_*       2     $Pmusic for a doom 2 level.
  1936.  
  1937. $pDP_*      vary  $PPC speaker sound effects. [7-1].
  1938. $pDS_*      vary  $PSoundcard sound effects. [7-1].
  1939.  
  1940. $0All the remaining entries in the directory, except the flats between F_START and F_END, and the "markers" like S_START, refer to lumps which are pictures, in the doom/wad graphic format described in chapter [5].  The flats are also pictures, but in a format described in chapter [6].
  1941. The next seven are full screen (320 by 200 pixel) pictures. After that, ST* are status-bar pictures, WI* are for the screens between levels, and M_* are for menus.
  1942. $t$I$L$u
  1943. $pHELP1           $PAd-screen says Register!, with some screen shots.
  1944. $pHELP2           $PActual help, all the controls explained.
  1945. $pTITLEPIC        $PMaybe this is the title screen? Gee, I dunno...
  1946. $pCREDIT          $PPeople at id Software who created this great game.
  1947. $pVICTORY2  r     $PScreen shown after a victorious end to episode 2.
  1948. $pPFUB1     r     $PA nice little rabbit minding his own peas and queues...
  1949. $pPFUB2     r     $P...a hint of what's waiting in Doom 2.
  1950.  
  1951. $pENDx      r     $Px=0-6, big red "THE END" gets shot up.
  1952. $pAMMNUMx         $Px=0-9. Small grey digits for ammo count (15/200 etc).
  1953. $pSTxBARy   1.1   $Px=M or A, y= L or R. Status bar used to be in pieces.
  1954. $pSTCHAT    1.1   $PStatus bar used to have a "chat" box.
  1955. $pSTRSNUMx  1.1   $Px=0-9. Small red digits.
  1956. $pSTWEAPx   1.1   $Px=0-5. COOL little weapon icons. Why'd they drop them?
  1957. $pSTFRAGS   1.1   $PTiny "FRAG" to be placed on top of part of status bar.
  1958. $pSTBAR     1.2   $PStatus Bar as used in deathmatches.
  1959. $pSTGNUMx         $Px=0-9. Small grey digits used on the "Arms" panel.
  1960. $pSTTNUMx         $Px=0-9. Big red digits used for Armor, Health, etc.
  1961. $pSTTMINUS  1.6   $PBig red "-" used for negative frags.
  1962. $pSTYSNUMx        $Px=0-9. Small yellow digits used on the "Arms" panel.
  1963. $pSTTPRCNT        $PBig red % used in Armor and Health.
  1964. $pSTKEYSx         $Px=0-5. Blue/Yellow/Red Keycards and Skullkeys.
  1965. $pSTDISK          $PDisk, used at bottom right corner during disk accesses.
  1966. $pSTCDROM   1.6   $PCD, used during CD-ROM accesses.
  1967. $pSTARMS          $P"Arms" panel which replaces "Frags" in non-deathmatch.
  1968. $pSTCFNxxx        $Pxxx=033-095, also 121. Small red ASCII characters.
  1969. $pSTFBx           $Px=0-3. Green/black/brown/red squares, for ST player faces.
  1970. $pSTPBx           $Px=0-3. Squares with bottoms, for inter-level screens.
  1971. $pSTFSTxy         $Px=0-4, y=0-2. Player face. x=0 is 100% health...x=4 is very low health. y=0 is glancing right, y=2 left.
  1972. $pSTFTLx0         $Px=0-4. Face looking left, player hurt from that direction.
  1973. $pSTFTRx0         $Px=0-4. Face looking right.
  1974. $pSTFOUCHx        $Px=0-4. Face looking surprised (hurt bad).
  1975. $pSTFEVLx         $Px=0-4. Face with a grin (when pick up new weapons).
  1976. $pSTFKILLx        $Px=0-4. Face with a grimace (when killing foes).
  1977. $pSTFGOD0         $PFace with yellow eyes (invulnerable).
  1978. $pSTFDEAD0        $PDead face.
  1979. $pBRDR_*          $PTiny pictures used as a border between a less-than-full screen view and the "outside" marbleized zone. TL is top left, BR bottom right, you can guess the rest.
  1980. $pWIBONUS   1.1   $PMedium sized red text "BONUS"
  1981. $pWISCORE   1.1   $P"SCORE"
  1982. $pWIMSTPx   1.1   $Px=0-3. Red text "ONE" to "FOUR".
  1983. $pWIMSTBx   1.1   $Px=0-3. Grey text "ONE" to "FOUR".
  1984. $pWIMINUS   1.6   $PSmall red "-" used for negative frags.
  1985. $pWIMAPx          $Px=0-2. 320x200 maps used on inter-level screens for e1,2,3.
  1986. $pWIAe0x0y        $Ppatches used to animate inter-level maps.
  1987. $pWIURH0          $P"YOU ARE HERE" with an arrow pointing left.
  1988. $pWIURH1          $P"YOU ARE HERE" with an arrow pointing right.
  1989. $pWISPLAT         $PSplat mark that indicates a completed level.
  1990. $pWIOSTK          $P"KILLS"
  1991. $pWIOSTI          $P"ITEMS"
  1992. $pWIF             $P"FINISHED"
  1993. $pWIMSTT          $P"TOTAL"
  1994. $pWIOSTS          $P"SCRT"
  1995. $pWIOSTF          $P"F."
  1996. $pWITIME          $P"TIME"
  1997. $pWIPAR           $P"PAR"
  1998. $pWIMSTAR         $P"YOU"
  1999. $pWIPCNT          $P"%"
  2000. $pWINUMx          $Px=0-9. Medium sized red digits.
  2001. $pWICOLON         $P":"
  2002. $pWISUCKS         $P"SUCKS"
  2003. $pWIFRGS          $P"FRAGS"
  2004. $pWILVxy          $Px=0-2, y=0-8. E(x+1)M(y+1) level names 
  2005. in grey/white letters.
  2006. $pWIPx            $Px=1-4. Red "P1" - "P4", for multiplayer summaries.
  2007. $pWIBPx           $Px=1-4. Grey "P1" - "P4"
  2008. $pWIKILRS         $PSmall red "KILLERS" going sideways up, for deathmatches.
  2009. $pWIVCTMS         $PSmall red "VICTIMS" for the top of the deathmatch chart.
  2010. $pWISCRT2         $P"SECRET"
  2011. $pWIENTER         $P"ENTERING"
  2012. $pM_DOOM          $PThe DOOM logo
  2013. $pM_RDTHIS        $PBig red "Read This!"
  2014. $pM_OPTION        $P"Options"
  2015. $pM_QUITG         $P"Quit Game"
  2016. $pM_NGAME         $P"New Game"
  2017. $pM_SKULL1        $PThe skull indicator with eyes lit.
  2018. $pM_SKULL2        $PThe skull indicator with eyes unlit.
  2019. $pM_THERMO        $PThe marker on e.g. the Sfx volume "thermometer".
  2020. $pM_THERMR        $PThe right end of the thermometer.
  2021. $pM_THERML        $PThe left end.
  2022. $pM_THERMM        $PThe middle, repeated over and over.
  2023. $pM_ENDGAM        $P"End Game"
  2024. $pM_PAUSE         $P"Pause"
  2025. $pM_MESSG         $P"Messages:"
  2026. $pM_MSGON         $P"on"
  2027. $pM_MSGOFF        $P"off"
  2028. $pM_EPISOD        $P"Which Epsiode?"
  2029. $pM_EPI1          $P"Knee-Deep In The Dead"
  2030. $pM_EPI2          $P"The Shores Of Hell"
  2031. $pM_EPI3          $P"Inferno"
  2032. $pM_HURT          $P"Hurt me plenty."
  2033. $pM_JKILL         $P"I'm too young to die."
  2034. $pM_ROUGH         $P"Hey, not too rough."
  2035. $pM_SKILL         $P"Choose Skill Level:"
  2036. $pM_NEWG          $P"NEW GAME" (title of New Game menu)
  2037. $pM_ULTRA         $P"Ultra-Violence."
  2038. $pM_NMARE   1.2   $P"Nightmare!"
  2039. $pM_SVOL          $P"Sound Volume"
  2040. $pM_OPTTTL        $P"OPTIONS" (title of Options menu)
  2041. $pM_SAVEG         $P"Save Game"
  2042. $pM_LOADG         $P"Load Game"
  2043. $pM_DISP          $P"Display"
  2044. $pM_MSENS         $P"Mouse sensitivity"
  2045. $pM_GDHIGH        $P"high"
  2046. $pM_GDLOW         $P"low"
  2047. $pM_DETAIL        $P"Graphic Detail:"
  2048. $pM_DISOPT        $P"DISPLAY OPTIONS"
  2049. $pM_SCRNSZ        $P"Screen Size"
  2050. $pM_SGTTL         $P"SAVE GAME"
  2051. $pM_LGTTL         $P"LOAD GAME"
  2052. $pM_SFXVOL        $P"Sfx Volume"
  2053. $pM_MUSVOL        $P"Music Volume"
  2054. $pM_LSLEFT        $PLoad/save box, left part
  2055. $pM_LSCNTR        $PLoad/save box, center part (repeated)
  2056. $pM_LSRGHT        $PLoad/save box, right part
  2057. $0
  2058. The following entries are markers that do not point to a lump; they have zero size:$u
  2059. $t$I$L
  2060. $pS_START         $Pmarks the start of the item/monster "sprite" section. See chapter [5] for the naming convention used here.
  2061. $pS_END           $Pis immediately after the last sprite.
  2062. $pP_START         $Pmarks the beginning of the wall patches.
  2063. $pP1_START          $Pbefore the first of the shareware wall patches.
  2064. $pP1_END            $Pafter the last of the shareware wall patches.
  2065. $pP2_START  r       $Pregistered wall patches.
  2066. $pP2_END    r       $Pregistered wall patches.
  2067. $pP_END           $Pmarks the end of the wall patches.
  2068. $pF_START         $Pmarks the beginning of the flats (floor textures).
  2069. $pF1_START          $Pshareware flats.
  2070. $pF1_END            $Pshareware flats.
  2071. $pF2_START  r       $Pregistered flats.
  2072. $pF2_END    r       $Pregistered flats.
  2073. $pF_END           $Pmarks the end of the flats.
  2074. +
  2075. UDS, Contents
  2076. =============
  2077. UDS [4] The Levels
  2078. =============
  2079. Each level has eleven directory entries and ten lumps: E[x]M[y] (or MAPxy in a DOOM 2 wad), THINGS, LINEDEFS, SIDEDEFS, VERTEXES, SEGS, SSECTORS, NODES, SECTORS, REJECT, and BLOCKMAP.
  2080. In the DOOM.WAD file, all of these entries are present for every level. In a pwad external file, they don't all need to be present. Whichever entries are in a pwad will be substituted for the originals. For example, a pwad with just two entries, E3M6 and THINGS, would use all the walls and such from the original E3M6, but could have a completely different set of THINGS.
  2081. +
  2082. UDS [4-1] ExMy or MAPxy
  2083. /
  2084. UDS [4-2] THINGS
  2085. /
  2086. UDS [4-3] LINEDEFS
  2087. /
  2088. UDS [4-4] SIDEDEFS
  2089. /
  2090. UDS [4-5] VERTEXES
  2091. /
  2092. UDS [4-6] SEGS
  2093. /
  2094. UDS [4-7] SSECTORS
  2095. /
  2096. UDS [4-8] NODES
  2097. /
  2098. UDS [4-9] SECTORS
  2099. /
  2100. UDS [4-10] REJECT
  2101. /
  2102. UDS [4-11] BLOCKMAP
  2103. /
  2104. ===========
  2105. UDS [4-1] ExMy or MAPxy
  2106. ===========
  2107. DOOM 1 levels have an ExMy label in a wad's directory. x is a single (ASCII) digit 1-3 for the episode number and y is 1-9 for the mission number.
  2108. DOOM 2 levels have a MAPxy label in a wad's directory. xy can range from (ASCII) 01 to 32, for the level number.
  2109. This label just indicates that the lump names following it are part of the designated level. The label does not actually point to a lump, and the size field in the directory is 0. The assignment of lumps to this level stops with either the next ExMy or MAPxy entry, or with a non-map entry like TEXTURE1.
  2110. Without these labels, there would be no way to differentiate amongst the many lumps named "THINGS", "LINEDEFS", etc.
  2111. +
  2112. UDS, Contents
  2113. =======
  2114. UDS [4-2] THINGS
  2115. ========
  2116. "Things" in DOOM are player start positions, monsters, weapons, keys, barrels, etc. The size of each THINGS lump will be a multiple of ten, since each thing requires ten bytes to describe it, in five <short> fields:$u
  2117.  
  2118. $t$I(1) X position of thing (at level's inception)
  2119. (2) Y position of thing
  2120. (3) Angle the thing faces. On the automap, 0 is east, 90 is north, 180 is west, 270 is south. This value is only used for monsters, player starts, deathmatch starts, and teleporter landing spots. Other things look the same from all directions. Values are rounded to the nearest 45 degree angle, so if the value is 80, it will actually face 90 - north.
  2121. (4) Type of thing, see next subsection, [4-2-1]
  2122. (5) Thing options, see [4-2-3]
  2123. +
  2124. UDS [4-2-1] Thing Types
  2125. /
  2126. UDS [4-2-2] Thing Sizes
  2127. /
  2128. UDS [4-2-3] Thing Options
  2129. /
  2130. UDS, Contents
  2131. =
  2132. UDS [4-2-1] Thing Types
  2133. =
  2134. Short 4 of 5, occupying bytes 6-7 of each thing record, specifies its kind. The table below summarizes the different types. They are listed in functional groups. You can easily get a numerical-order list by extracting this table and SORTing it.
  2135. $3$l
  2136. Dec/Hex The thing's number in decimal and hexadecimal. This is the number used in the THINGS lump on a level (ExMy or MAPxx).
  2137. V       Version of DOOM needed to use this object: no mark indicates all versions have this object
  2138. r         requires registered DOOM or DOOM 2
  2139. 2         requires DOOM 2
  2140. Spr     The sprite name associated with this thing. This is the first four letters of the lumps that are pictures of this thing.
  2141. seq.    The sequence of frames displayed. "-" means it displays nothing.  Unanimated things will have just an "a" here, e.g. a backpack's only picture can be found in the wad under BPAKA0. Animated things will show the order that their frames are displayed (they cycle back after the last one). So the blue key alternates between BKEYA0 and BKEYB0. The soulsphere uses SOULA0-SOULB0-C0-D0-C0-B0 then repeats. Thing 15, a dead player, is PLAYN0.
  2142. +       Monsters and players and barrels. They can be hurt, and they have a more complicated sprite arrangement. See chapter [5].
  2143. CAPITAL Monsters, counts toward the KILL ratio at the end of a level.
  2144. #       An obstacle, players and monsters can't move through it.
  2145. ^       Hangs from the ceiling, or floats (if a monster).
  2146. $       A regular item that players may get.
  2147. !       An artifact item; counts toward the ITEM ratio at level's end. Note that 2025, the radiation suit, was an ITEM in version 1.2, but it is not an ITEM in version 1.666 on. Also note that 2022 and 2024, invulnerability and invisibility, do not respawn in -altdeath games.
  2148. $2
  2149. Dec. Hex  V Spr  seq.     Thing is:
  2150.   -1 ffff   ---- -        (nothing)
  2151.    0 0000   ---- -        (nothing)
  2152.    1 0001   PLAY +        Player 1 start (Player 1 start needed on ALL levels)
  2153.    2 0002   PLAY +        Player 2 start (Player starts 2-4 are needed in)
  2154.    3 0003   PLAY +        Player 3 start (cooperative mode multiplayer games)
  2155.    4 0004   PLAY +        Player 4 start
  2156.   11 000b   ---- -        Deathmatch start positions. Should have >= 4/level
  2157.   14 000e   ---- -        Teleport landing. Where players/monsters land when
  2158.   14                        they teleport to the SECTOR containing this thing
  2159.  
  2160. 3004 0bbc   POSS +      # FORMER HUMAN: regular pistol-shooting zombieman
  2161.   84 0054 2 SSWV +      # WOLFENSTEIN SS: guest appearance by Wolf3D blue guy
  2162.    9 0009   SPOS +      # FORMER HUMAN SERGEANT: black armor, shotgunners
  2163.   65 0041 2 CPOS +      # HEAVY WEAPON DUDE: red armor, chaingunners
  2164. 3001 0bb9   TROO +      # IMP: brown, hurl fireballs
  2165. 3002 0bba   SARG +      # DEMON: pink, muscular bull-like chewers
  2166.   58 003a   SARG +      # SPECTRE: invisible version of the DEMON
  2167. 3006 0bbe r SKUL +     ^# LOST SOUL: flying flaming skulls, they really bite
  2168. 3005 0bbd r HEAD +     ^# CACODEMON: red one-eyed floating heads. Behold...
  2169.   69 0045 2 BOS2 +      # HELL KNIGHT: grey-not-pink BARON, weaker
  2170. 3003 0bbb   BOSS +      # BARON OF HELL: cloven hooved minotaur boss
  2171.   68 0044 2 BSPI +      # ARACHNOTRON: baby SPIDER, shoots green plasma
  2172.   71 0047 2 PAIN +     ^# PAIN ELEMENTAL: shoots LOST SOULS, deserves its name
  2173.   66 0042 2 SKEL +      # REVENANT: Fast skeletal dude shoots homing missles
  2174.   67 0043 2 FATT +      # MANCUBUS: Big, slow brown guy shoots barrage of fire
  2175.   64 0040 2 VILE +      # ARCH-VILE: Super-fire attack, ressurects the dead!
  2176.    7 0007 r SPID +      # SPIDER MASTERMIND: giant walking brain boss
  2177.   16 0010 r CYBR +      # CYBER-DEMON: robo-boss, rocket launcher
  2178.  
  2179.   88 0058 2 BBRN +      # BOSS BRAIN: Horrifying visage of the ultimate demon
  2180.   89 0059 2 -    -        Boss Shooter: Shoots spinning skull-blocks
  2181.   87 0057 2 -    -        Spawn Spot: Where Todd McFarlane's guys appear
  2182.  
  2183. 2005 07d5   CSAW a      $$ Chainsaw
  2184. 2001 07d1   SHOT a      $$ Shotgun
  2185.   82 0052 2 SGN2 a      $$ Double-barreled shotgun
  2186. 2002 07d2   MGUN a      $$ Chaingun, gatling gun, mini-gun, whatever
  2187. 2003 07d3   LAUN a      $$ Rocket launcher
  2188. 2004 07d4 r PLAS a      $$ Plasma gun
  2189. 2006 07d6 r BFUG a      $$ Bfg9000
  2190. 2007 07d7   CLIP a      $$ Ammo clip
  2191. 2008 07d8   SHEL a      $$ Shotgun shells
  2192. 2010 07da   ROCK a      $$ A rocket
  2193. 2047 07ff r CELL a      $$ Cell charge
  2194. 2048 0800   AMMO a      $$ Box of Ammo
  2195. 2049 0801   SBOX a      $$ Box of Shells
  2196. 2046 07fe   BROK a      $$ Box of Rockets
  2197.   17 0011 r CELP a      $$ Cell charge pack
  2198.    8 0008   BPAK a      $$ Backpack: doubles maximum ammo capacities
  2199.  
  2200. 2011 07db   STIM a      $$ Stimpak
  2201. 2012 07dc   MEDI a      $$ Medikit
  2202. 2014 07de   BON1 abcdcb ! Health Potion +1% health
  2203. 2015 07df   BON2 abcdcb ! Spirit Armor +1% armor
  2204. 2018 07e2   ARM1 ab     $$ Green armor 100%
  2205. 2019 07e3   ARM2 ab     $$ Blue armor 200%
  2206.   83 0053 2 MEGA abcd   ! Megasphere: 200% health, 200% armor
  2207. 2013 07dd   SOUL abcdcb ! Soulsphere, Supercharge, +100% health
  2208. 2022 07e6 r PINV abcd   ! Invulnerability
  2209. 2023 07e7 r PSTR a      ! Berserk Strength and 100% health
  2210. 2024 07e8   PINS abcd   ! Invisibility
  2211. 2025 07e9   SUIT a     (!)Radiation suit - see notes on ! above
  2212. 2026 07ea   PMAP abcdcb ! Computer map
  2213. 2045 07fd   PVIS ab     ! Lite Amplification goggles
  2214.  
  2215.    5 0005   BKEY ab     $$ Blue keycard
  2216.   40 0028 r BSKU ab     $$ Blue skullkey
  2217.   13 000d   RKEY ab     $$ Red keycard
  2218.   38 0026 r RSKU ab     $$ Red skullkey
  2219.    6 0006   YKEY ab     $$ Yellow keycard
  2220.   39 0027 r YSKU ab     $$ Yellow skullkey
  2221.  
  2222. 2035 07f3   BAR1 ab+    # Barrel; not an obstacle after blown up (BEXP sprite)
  2223.   72 0048 2 KEEN a+     # A guest appearance by Billy
  2224.  
  2225.   48 0030   ELEC a      # Tall, techno pillar
  2226.   30 001e r COL1 a      # Tall green pillar
  2227.   32 0020 r COL3 a      # Tall red pillar
  2228.   31 001f r COL2 a      # Short green pillar
  2229.   36 0024 r COL5 ab     # Short green pillar with beating heart
  2230.   33 0021 r COL4 a      # Short red pillar
  2231.   37 0025 r COL6 a      # Short red pillar with skull
  2232.   47 002f r SMIT a      # Stalagmite: small brown pointy stump
  2233.   43 002b r TRE1 a      # Burnt tree: gray tree
  2234.   54 0036 r TRE2 a      # Large brown tree
  2235.  
  2236. 2028 07ec   COLU a      # Floor lamp
  2237.   85 0055 2 TLMP abcd   # Tall techno floor lamp
  2238.   86 0056 2 TLP2 abcd   # Short techno floor lamp
  2239.   34 0022   CAND a        Candle
  2240.   35 0023   CBRA a      # Candelabra
  2241.   44 002c r TBLU abcd   # Tall blue firestick
  2242.   45 002d r TGRE abcd   # Tall green firestick
  2243.   46 002e   TRED abcd   # Tall red firestick
  2244.   55 0037 r SMBT abcd   # Short blue firestick
  2245.   56 0038 r SMGT abcd   # Short green firestick
  2246.   57 0039 r SMRT abcd   # Short red firestick
  2247.   70 0046 2 FCAN abc    # Burning barrel
  2248.  
  2249.   41 0029 r CEYE abcb   # Evil Eye: floating eye in symbol, over candle
  2250.   42 002a r FSKU abc    # Floating Skull: flaming skull-rock
  2251.  
  2252.   49 0031 r GOR1 abcb  ^# Hanging victim, twitching
  2253.   63 003f r GOR1 abcb  ^  Hanging victim, twitching
  2254.   50 0032 r GOR2 a     ^# Hanging victim, arms out
  2255.   59 003b r GOR2 a     ^  Hanging victim, arms out
  2256.   52 0034 r GOR4 a     ^# Hanging pair of legs
  2257.   60 003c r GOR4 a     ^  Hanging pair of legs
  2258.   51 0033 r GOR3 a     ^# Hanging victim, 1-legged
  2259.   61 003d r GOR3 a     ^  Hanging victim, 1-legged
  2260.   53 0035 r GOR5 a     ^# Hanging leg
  2261.   62 003e r GOR5 a     ^  Hanging leg
  2262.   73 0049 2 HDB1 a     ^# Hanging victim, guts removed
  2263.   74 004a 2 HDB2 a     ^# Hanging victim, guts and brain removed
  2264.   75 004b 2 HDB3 a     ^# Hanging torso, looking down
  2265.   76 004c 2 HDB4 a     ^# Hanging torso, open skull
  2266.   77 004d 2 HDB5 a     ^# Hanging torso, looking up
  2267.   78 004e 2 HDB6 a     ^# Hanging torso, brain removed
  2268.  
  2269.   25 0019 r POL1 a      # Impaled human
  2270.   26 001a r POL6 ab     # Twitching impaled human
  2271.   27 001b r POL4 a      # Skull on a pole
  2272.   28 001c r POL2 a      # 5 skulls shish kebob
  2273.   29 001d r POL3 ab     # Pile of skulls and candles
  2274.   10 000a   PLAY w        Bloody mess (an exploded player)
  2275.   12 000c   PLAY w        Bloody mess, this thing is exactly the same as 10
  2276.   24 0018   POL5 a        Pool of blood and flesh
  2277.   79 004f 2 POB1 a        Pool of blood
  2278.   80 0050 2 POB2 a        Pool of blood
  2279.   81 0051 2 BRS1 a        Pool of brains
  2280.   15 000f   PLAY n        Dead player
  2281.   18 0012   POSS l        Dead former human
  2282.   19 0013   SPOS l        Dead former sergeant
  2283.   20 0014   TROO m        Dead imp
  2284.   21 0015   SARG n        Dead demon
  2285.   22 0016 r HEAD l        Dead cacodemon
  2286.   23 0017 r SKUL k        Dead lost soul, invisible (they blow up when killed)
  2287. +
  2288. UDS, Contents
  2289. =
  2290. UDS [4-2-2] Thing Sizes
  2291. =
  2292. The list below gives the radius, height, mass, speed, and toughness of all the monsters in DOOM 1 and 2. Almost all non-monster things only differ in their "radius", dependent on whether they are obstacles or not. For collision purposes, things are NOT circular. They occupy a square whose side equals slightly more than 2 times the radius. This square does not turn, it is always aligned with the x and y axes of a level.  Consider a simple collision detection in a coordinate plane:
  2293. $u
  2294.     IF (ABS(x1-x2) =< (r1+r2)) AND (ABS(y1-y2) =< (r1+r2)) THEN *collision*
  2295.  
  2296. $UThis will result in square objects centered on their (x,y) positions, and that is the behavior that DOOM objects exhibit.
  2297. I don't know why the horizontal size is "slightly more" than 2 times the radius, but it is. A player cannot enter a corridor of width 32, but can enter a corridor of width 33. Experiments have shown that no monster can enter a corridor that is exactly (2*radius) wide. It must be bigger. Moving up to the next multiple of 8 is a good idea, if not 16 or 32.
  2298. Monsters CAN enter sectors that are exactly "Height" high. But obstacles are infinitely high for collision purposes. A player on a very high ledge might not be able to jump off, because of an obstacle right next to him, even though it is far below him.
  2299. Height is also used when under a crushing ceiling, and to determine if an object can move from one sector to another. The space between the highest floor and the lowest ceiling must be "Height" or greater for the object to fit.
  2300. Toughness indicates how much punishment a monster can take until it dies. Bullets do 10 damage, Shotgun shells 70 (7 pellets, each is 10), Plasma 20, Rockets 100, and the BFG does 1000 for a direct hit. There's more info on this stuff in the DOOM FAQ.
  2301. $2
  2302. Dec. Hex  Radius Height Mass Tough Speed  Sprite name or class of things:
  2303.  
  2304. -    -      16     56    100  (100)    -  PLAY
  2305. 3004 0bbc   20     56    100    20     8  POSS
  2306.   84 0054   20     56    100    50     8  SSWV
  2307.    9 0009   20     56    100    30     8  SPOS
  2308.   65 0041   20     56    100    70     8  CPOS
  2309. 3001 0bb9   20     56    100    60     8  TROO
  2310. 3002 0bba   30     56    400   150    10  SARG 
  2311.   58 003a   30     56    400   150    10  SARG (Inviso model)
  2312. 3006 0bbe   16     56     50   100     8  SKUL
  2313. 3005 0bbd   31     56    400   400     8  HEAD
  2314.   69 0045   24     64   1000   500     8  BOS2
  2315. 3003 0bbb   24     64   1000  1000     8  BOSS
  2316.   68 0044   64     64    600   500    12  BSPI
  2317.   71 0047   31     56    400   400     8  PAIN
  2318.   66 0042   20     56    500   300    10  SKEL
  2319.   67 0043   48     64   1000   600     8  FATT
  2320.   64 0040   20     56    500   700    15  VILE
  2321.    7 0007  128    100   1000  3000    12  SPID
  2322.   16 0010   40    110   1000  4000    16  CYBR
  2323.   88 0058   16     16   6666   250     0  BBRN
  2324.   72 0048   16     72   6666   100     0  KEEN
  2325. 2035 07f3   10     42    100    20     0  BAR1
  2326.    -    -   20     16      -     -     -  most non-obstacles (e.g. gettables)
  2327.    -    -   16     16      -     -     -  most obstacles
  2328.   54 0036   32     16      -     -     -  large brown tree
  2329. +
  2330. UDS, Contents
  2331. =
  2332. UDS [4-2-3] Thing Options
  2333. =
  2334. Short 5 of 5, occupying bytes 8-9 of each thing record, control a few options, according to which bits are set:
  2335. $3
  2336. bit 0   the THING is present at skill 1 and 2
  2337. bit 1   the THING is present at skill 3 (hurt me plenty)
  2338. bit 2   the THING is present at skill 4 and 5 (ultra-violence, nightmare)
  2339. bit 3   indicates a deaf guard.
  2340. bit 4   means the THING only appears in multiplayer mode.
  2341. bits 5-15 have no effect.
  2342. $0
  2343. The skill settings are most used with the monsters, of course...the most common skill level settings are hex 07/0f (on all skills), 06/0e (on skill 3-4-5), and 04/0c (only on skill 4-5). Unusual skill settings are perfectly allowable, e.g. hex 05 for a thing which is present on skill 1, 2, 4, and 5, but not skill 3.
  2344. "Deaf guard" only has meaning for monsters, who will not attack until they see a player if they are deaf. Otherwise, they will activate when they hear gunshots, etc. (including the punch!). Sound does not travel through solid walls (walls that are solid at the time of the noise).  Also, lines can be set so that sound does not pass through them (see [4-3-1] bit 6). This option is also known as the "ambush" option (or flag, or attribute).
  2345. +
  2346. UDS, Contents
  2347. =
  2348. UDS [4-3] LINEDEFS
  2349. =
  2350. Each linedef represents a line from one of the VERTEXES to another, and each linedef's record is 14 bytes, containing 7 <short> fields:
  2351. $3
  2352. (1) from the VERTEX with this number (the first vertex is 0).
  2353. (2) to the VERTEX with this number (31 is the 32nd vertex).
  2354. (3) flags, see [4-3-1] below.
  2355. (4) types, see [4-3-2] below.
  2356. (5) is a "tag" or "trigger" number which ties this line's effect type to all SECTORS that have the same tag number (in their last field).
  2357. (6) number of the "right" SIDEDEF for this linedef.
  2358. (7) "left" SIDEDEF, if this line adjoins 2 SECTORS. Otherwise, it is equal to -1 (FFFF hex).
  2359. $0
  2360. "right" and "left" are based on the direction of the linedef as indicated by the "from" and "to", or "start" and "end", VERTEXES.  This sketch should make it clear:
  2361. $u$t
  2362.           left side                    right side
  2363.     start -----------------> end <----------------- start
  2364.           right side                    left side
  2365. $0
  2366. IMPORTANT: All lines must have a right side. If it is a one-sided line, then it must go the proper direction, so its single side is facing the sector it is part of. DOOM will crash on a level that has a line with no right side.
  2367. +
  2368. UDS [4-3-1] Linedef Flags
  2369. /
  2370. UDS [4-3-2] Linedef Types
  2371. /
  2372. UDS, Contents
  2373. =
  2374. UDS [4-3-1] Linedef Flags
  2375. =
  2376. The third <short> field of each linedef controls some attributes of that line. These attributes (aka flags) are indicated by bits. If the bit is set (equal to 1), the condition is true for that line. If the bit is not set (equal to 0), the condition is not true. Note that the "unpegged" flags cannot be independently set for the two SIDEDEFs of a line. Here's a list of the flags, followed by a discussion of each:
  2377. $3
  2378. bit      Condition
  2379. 0       Impassible
  2380. 1       Block Monsters
  2381. 2       Two-sided
  2382. 3       Upper Unpegged
  2383. 4       Lower Unpegged
  2384. 5       Secret
  2385. 6       Block Sound
  2386. 7       Not on Map
  2387. 8       Already on Map
  2388. 9-15   unused
  2389.  
  2390. 0 (Impassible) - Players and monsters cannot cross this line. Note that if there is no sector on the other side, they can't go through the line anyway, regardless of the flags.
  2391. 1 (Block Monsters) - Monsters cannot cross this line.
  2392. 2 (Two-sided) - The linedef's two sidedefs can have "-" as a texture, which in this case means "transparent". If this flag is not set, the sidedefs can't be transparent: if "-" is viewed, it will result in the "hall of mirrors" effect. However, a linedef CAN have two non-transparent sidedefs, even if this flag is not set, as long as it is between two sectors.
  2393. $TAnother side effect of this flag is that if it is set, then gunfire (pistol, shotgun, chaingun) can go through it. If this flag is not set, gunfire cannot go through the line. Projectiles (rockets, plasma etc.) are not restricted this way. They can go through as long as there's a sector on the other side (and the sector heights allow it). 
  2394. Finally, monsters can see through and attack through two-sided lines, despite any of the line's other flag settings and textures (once again, provided sector heights and the REJECT [4-10] allow it).$3  
  2395. 3 (Upper unpegged) - The upper texture is pasted onto the wall from the top down instead of from the bottom up like usual.   Upper textures normally have the bottom of the wall texture to be drawn lined up with the bottom of the "upper" space in which it is to be drawn (sidedef Y offsets then apply [4-4]). This can result in the upper texture being misaligned with a neighboring "middle" texture. To help solve this problem, common at "windows", this flag can be set.
  2396. $TIf the upper texture is unpegged, it is drawn with the wall texture's top row at the ceiling, just like middle and lower textures are usually drawn. This can help realign the upper texture with a neighbor.
  2397. The article TEXTURES, cited in appendix [A-4] gives a great deal more explanation on the "unpegged" flags and how to use them.$3  
  2398. 4 (Lower unpegged) - Lower and middle textures are drawn from the bottom up, instead of from the top down like usual.
  2399. $TThis is also commonly used on lower textures under "windows". It is also used on doorjambs, because when the door opens, the sector ceiling is rising, so the "sides" (the doorjambs), which are middle textures, will be drawn from the ever-changing ceiling height down, and thus will appear to be "moving". Unpegging them will make them be drawn from the floor up, and since the floor height doesn't change when a door opens, then will not move.
  2400. There's one slight difference with lower textures being unpegged - they are not necessarily drawn with the bottom of the wall texture placed at the bottom of the wall. The height of the facing sector and the height of the wall texture are taken into account. So if the sector is 160 high, and the wall texture is 128 high, then lower unpegged will cause the 32nd row of the wall texture to be at the floor, NOT the 128th row. This of course excludes sidedef Y offsets, which are applied AFTER unpegged flags do their stuff.$3  
  2401. 5 (Secret) - On the automap, this line appears in red like a normal solid wall that has nothing on the other side. This is useful in protecting secret doors and such. Note that if the sector on the other side of this "secret" line has its floor height HIGHER than the sector on the facing side of the secret line, then the map will show the lines beyond and thus give up the secret.
  2402. $TAlso note that this flag has NOTHING to do with the SECRETS ratio on inter-level screens. That's done with special sector 9 (see [4-9-1]).$3  
  2403. 6 (Block Sound) - For purposes of monsters hearing sounds and thus becoming alerted. Every time a player fires a weapon, the "sound" of it travels from sector to sector, alerting all non-deaf monsters in each new sector. But the sound will die when it hits a second line with this flag. The sound can cross one such line, but not two. All possible routes for the sound to take are taken, so it can get to some out-of-the-way places. Another thing that blocks sound, instantly, is incompatible sector heights. Sound can go from a sector with 0/72 floor/ceiling heights to one with 64/192, but the sound CANNOT go from a 0/128 sector to an adjacent 128/256 sector.
  2404. 7 (Not on Map) - The line is not shown on the automap, even if the computer all-map power up is acquired.
  2405. 8 (Already on Map) - When the level is begun, this line is already on the automap, even though it hasn't been seen (in the display) yet.  Normally lines only get mapped once part of the line has been seen in the display window.
  2406. $TAutomap line colors: Red lines indicate the line is one-sided, that there is a sector on only one side (or the line is marked secret). Brown lines are between two sectors with different floor heights but the same ceiling height. Yellow lines are between two sectors with different ceiling heights and the same or different floor heights.  Gray lines are as-yet-unseen lines revealed by the computer all-map.  Without the all-map, lines between sectors with identical floor and ceiling heights don't show up. With it, they are gray.
  2407. +
  2408. UDS, Contents
  2409. =
  2410. UDS [4-3-2] Linedef Types
  2411. =
  2412. The <short> in field 4 of 7 of a linedef can control various special effects like doors opening, floors moving, etc. Some of them must be activated by "using" them, like switches, and some of them are activated when they are walked over. There are a huge number of ways to use these effects, but it's all done by using one of a hundred or so line function types.
  2413. The most common way they work is this: a player walks across a line or activates (presses the spacebar or the use key) right in front of a line. That line has a function type that is non-zero. It also has a tag number. Then ALL sectors on the level with the same tag number, that are not already engaged in some action, undergo the effects that the linedef type number dictates. Note that the tag numbers are NOT the sector numbers, nor the linedef numbers. A tag number is in a lindef's 5th <short> field, and a sector's last <short> field.
  2414.  
  2415. Explanations of all the abbreviations in the table:
  2416. $3$l
  2417. Val     The value of the linedef "type" field (#4). If you want them in numerical order, use SORT or something.
  2418. *       This line function only works in 1.666 and up
  2419. Class   The category of the effect
  2420. Act     Activation. How the linedef's effect is activated.
  2421. n       does NOT require a tag number (see note 5 below)
  2422. W       walk-over activation
  2423. S       switch ("use" - default config is spacebar)
  2424. G       gunfire (pistol, shotgun, chaingun) cross or hit line
  2425. 1       the line may be activated once only
  2426. R       potentially repeatable activation
  2427. &       affected sectors "locked out" from further changes. See notes 9/10.
  2428. m       Monster actions can activate the line's effect
  2429. Sound   The type of noise made by moving sectors
  2430. Speed   How quickly a floor moves up/down etc.
  2431. Tm      Time - how long it "rests"; doors "rest" when they've gone as high as they're going to go, lifts "rest" at the bottom, etc.
  2432. Chg     Change - some of them cause a floor texture change and/or special sector change. See note 11 below.
  2433. T       Trigger model, see note 11 below.
  2434. N       Numeric model, see note 11 below.
  2435. X       Floor texture is transferred, and Sector type 0.
  2436. P       Special Sector types 4, 5, 7, 9, 11, 16 transfer.
  2437. Effect  What happens to the affected sector(s).
  2438. open    The ceiling goes (up) to LEC-4.
  2439. close   The ceiling goes (down) to the floor level.
  2440. up      Will move up at specified speed if the destination is above.If the destination is below, it arrives there instantly.
  2441. down    Will move down at specified speed if the destination is below.If the destination is above, it arrives there instantly.
  2442. open   The door can be activated while moving. If it's open or opening,
  2443. close   it closes. If it's closed or closing, it opens, then pauses, then closes.
  2444. open,   The door can only be activated if it is in the closed state. close It opens, pauses, then closes.
  2445. lift    The floor goes down to LIF, rests, then back up to original height.
  2446. L       lowest
  2447. H       highest
  2448. C       ceiling
  2449. F       floor
  2450. E       adjacent sectors, excluding the affected sector
  2451. I       adjacent sectors, including the affected sector
  2452. nh      next-higher, i.e. LEF that is higher than source.
  2453. $0
  2454. More notes and longer discussions related to these terms:
  2455. $3$l
  2456. 1.  "Adjacent" is any sector that shares a LINEDEF with the tagged sector
  2457. (sectors are adjacent to themselves).
  2458. 2.  All S activations and the teleporters only work from the RIGHT side
  2459. of the linedef.
  2460. 3.  For teleporters, if more than 1 sector is tagged the same and each
  2461. has a teleport landing THING, then the lowest numbered sector is the
  2462. destination.
  2463. 4.  Floors that raise up an absolute height (up 24, 32) will go up INTO
  2464. ceilings, so using the WR and SR types of these in levels is unwise.
  2465. 5.  A few of the linedef types don't require tag numbers: the end-level
  2466. switches, the scrolling wall type 48 (0x30), and the "manual" doors which
  2467. operate on the sector facing the left side of the linedef with the manual
  2468. door line type.
  2469. 666.  Here's the terms id uses for different types of activations:
  2470.     Manual: nSR and nS1 doors
  2471.     Trigger: W1
  2472.     Retrigger: WR
  2473.     Switch: S1
  2474.     Button: SR
  2475.     Impact: G
  2476.     Effect: line 48 is the only one
  2477. 7.  The "moving floors" go up to a maximum of HIF and go down to a minimum of LIF. Why they sometimes go up first and sometimes down is still a mystery to me.
  2478. 8.  The "crushing ceilings" go from their original ceiling height down to (floor + 8), then back up. While crushing a creature, their downward speed slows considerably. "Fast hurt" does about 120% total damage per crush, and "slow hurt" grabs you and does somewhere around 1000-2000% total damage per crush.
  2479. 9.  The & symbol indicates that a sector cannot be affected any more by other line types after it has performed this effect, even if it has finished. These are the floor-texture-changers and... (keep reading)
  2480. 10. Moving floors and crushing ceilings also "lock out" further changes to the sectors affected, EXCEPT for restarting the moving floor or crushing ceiling. If a line triggers a type 6 crushing ceiling in a sector, then it is stopped, then ANY other line with a "crush" type that is tagged to the same sector will cause the type 6 crusher to start again, with its original maximum and minimum ceiling heights.
  2481. 11. Some line types cause floor textures and/or some special sector types (see [4-9-1]) to transfer to the tagged sector. The tagged sectors' floor and/or special sector (SS) type will change to match that of the "model" sector. The TRIGGER model gets the info from the sector that the activating line's right side faces. The NUMERIC model gets the info from the sector on the other side of the lowest numbered two-sided linedef that has one side in the tagged sector.  All of these "change" line types transfer the floor texture. Also, they all can pass a special sector trait of "0" or "nothing", i.e. if the destination is an acid-floor or "damaging" sector, then any of these lines can erase the damaging effect. Lines 59, 93, 37, 84, and 9 (see
  2482. note 12 for more specifics on line type 9) also have the ability to transfer the "secret" trait of SS 9, and the damaging traits of SS 4, 5, 7, 11, and 16. None of the "blinking light" effects of SSs can be transferred. SS 4 "blinks" and causes damage, but only the damaging part can be transferred. SS 11 also turns off god-mode and causes a level END when health <11%, this characteristic is part of SS 11, and cannot be
  2483. isolated via fancy transfers.
  2484. 12. Line type 9 is a special one. The definitive example is the chainsaw pillar on E1M2. Take the lowest-numbered linedef that has a sidedef in the tagged sector. If that linedef is one-sided, nothing happens. If it
  2485. is 2-sided, then the tagged sector's floor will move down to match the 2nd sector's floor height (or it will jump instantly up if it was below, like other floors that are supposed to move "down").  If this 2nd sector CONTAINS the tagged sector, i.e. all the linedefs with a sidedef in the tagged sector have their other sidedef in the 2nd sector, then this 2nd sector is the "donut". This donut's floor will move "up" to match the floor height of the sector on the other side of the DONUT's lowest-numbered linedef, excluding those linedefs that are shared with the "donut hole" central sector. Also, the donut will undergo a floor texture change and special sector type change to match the "outside". The donut sector does not have to be completely surrounded by another sector (i.e. it can have 1-sided linedefs), but if its lowest-numbered linedef is not 2-sided, a minor glitch results: the donut and the donut-hole both move to a strange height, and the donut changes floor texture to TLITE6_6 - the last flat in the directory.  Note that if the donut hole and the donut are both going to move, the donut hole is going to move to match the height that the donut is "going to". In other words, the whole thing will be at a single height when they're done, and this is the height of the "outside" sector that borders the donut.
  2486.   Whew!
  2487. 13. Line types 30 and 96, "up ShortestLowerTexture" means that affected sector(s) floors go up a number of units equal to the height of the shortest "lower" texture facing out from the sector(s).
  2488. 14. STAIRS. Any sector tagged to a stair-raiser line will go up 8. Now find the lowest-numbered 2-sided linedef whose RIGHT side faces this sector (the first step). The sector on the other side of the lindedef becomes the next step, and its floor height changes to be 8 above the previous step (it raises up if it was lower, or it changes instantly if it was higher). This process continues as long as there are 2-sided
  2489. lines with right sides facing each successive step. A couple things will stop the stairway:
  2490.     (a) no 2-sided linedef whose right side faces the current step
  2491.     (b) a sector with a different floor texture
  2492.     (c) a sector that has already been moved by this stairway (this stops ouroboros stairways that circle around to repeat themselves)
  2493.     (d) "locked-out" sectors that can't change their floor height anymore
  2494. The component steps of a stairway can have any shape or size.  The turbo stairs (100, 127) work just like regular stairs except that each step goes up 16 not 8, and rising steps can crush things between themselves and the ceiling.
  2495. 15. Line types 78 and 85 do NOTHING as of version 1.666.
  2496. +
  2497. UDS Linedef types list
  2498. UDS, Contents
  2499. =
  2500. UDS Linedef types list
  2501. =
  2502. $u$p$t$i$j
  2503. Val   Class Act  Sound Speed Tm Chg Effect
  2504.  
  2505. SPECIAL (Continuous effect, doesn't need triggereing)
  2506.  48   Spec  n--  -     -     -  -   Scrolling wall
  2507.  
  2508. LOCAL DOORS ("MANUAL" DOORS)
  2509.   1   mDoor nSRm door  med   4  -   open/close
  2510.  26   mDoor nSR  door  med   4  -   open/close BLUE KEY
  2511.  28   mDoor nSR  door  med   4  -   open/close RED KEY
  2512.  27   mDoor nSR  door  med   4  -   open/close YELLOW KEY
  2513.  31   mDoor nS1  door  med   -  -   open
  2514.  32   mDoor nS1  door  med   -  -   open BLUE KEY
  2515.  33   mDoor nS1  door  med   -  -   open RED KEY
  2516.  34   mDoor nS1  door  med   -  -   open YELLOW KEY
  2517.  46   mDoor nGR  door  med   -  -   open
  2518. 117 * mDoor nSR  blaze turbo 4  -   open/close
  2519. 118 * mDoor nS1  blaze turbo -  -   open
  2520.  
  2521. REMOTE DOORS
  2522.   4   rDoor  W1  door  med   4  -   open,close
  2523.  29   rDoor  S1  door  med   4  -   open,close
  2524.  90   rDoor  WR  door  med   4  -   open,close
  2525.  63   rDoor  SR  door  med   4  -   open,close
  2526.   2   rDoor  W1  door  med   -  -   open
  2527. 103   rDoor  S1  door  med   -  -   open
  2528.  86   rDoor  WR  door  med   -  -   open
  2529.  61   rDoor  SR  door  med   -  -   open
  2530.   3   rDoor  W1  door  med   -  -   close
  2531.  50   rDoor  S1  door  med   -  -   close
  2532.  75   rDoor  WR  door  med   -  -   close
  2533.  42   rDoor  SR  door  med   -  -   close
  2534.  16   rDoor  W1  door  med   30 -   close, then opens
  2535.  76   rDoor  WR  door  med   30 -   close, then opens
  2536. 108 * rDoor  W1  blaze turbo 4  -   open,close
  2537. 111 * rDoor  WR  blaze turbo 4  -   open,close
  2538. 105 * rDoor  S1  blaze turbo 4  -   open,close
  2539. 114 * rDoor  SR  blaze turbo 4  -   open,close
  2540. 109 * rDoor  W1  blaze turbo -  -   open
  2541. 112 * rDoor  S1  blaze turbo -  -   open
  2542. 106 * rDoor  WR  blaze turbo -  -   open
  2543. 115 * rDoor  SR  blaze turbo -  -   open
  2544. 110 * rDoor  W1  blaze turbo -  -   close
  2545. 113 * rDoor  S1  blaze turbo -  -   close
  2546. 107 * rDoor  WR  blaze turbo -  -   close
  2547. 116 * rDoor  SR  blaze turbo -  -   close
  2548. 133 * rDoor  S1  blaze turbo -  -   open BLUE KEY
  2549.  99 * rDoor  SR  blaze turbo -  -   open BLUE KEY
  2550. 135 * rDoor  S1  blaze turbo -  -   open RED KEY
  2551. 134 * rDoor  SR  blaze turbo -  -   open RED KEY
  2552. 137 * rDoor  S1  blaze turbo -  -   open YELLOW KEY
  2553. 136 * rDoor  SR  blaze turbo -  -   open YELLOW KEY
  2554.  
  2555. CEILINGS
  2556.  40   Ceil   W1  mover slow  -  -   up to HEC
  2557.  41   Ceil   S1  mover slow  -  -   down to floor
  2558.  43   Ceil   SR  mover slow  -  -   down to floor
  2559.  44   Ceil   W1  mover slow  -  -   down to floor + 8
  2560.  49   Ceil   S1  mover slow  -  -   down to floor + 8
  2561.  72   Ceil   WR  mover slow  -  -   down to floor + 8
  2562.  
  2563. LIFTS
  2564.  10   Lift   W1  lift  fast  3  -   lift
  2565.  21   Lift   S1  lift  fast  3  -   lift
  2566.  88   Lift   WRm lift  fast  3  -   lift
  2567.  62   Lift   SR  lift  fast  3  -   lift
  2568. 121 * Lift   W1  lift  turbo 3  -   lift
  2569. 122 * Lift   S1  lift  turbo 3  -   lift
  2570. 120 * Lift   WR  lift  turbo 3  -   lift
  2571. 123 * Lift   SR  lift  turbo 3  -   lift
  2572.  
  2573. FLOORS
  2574. 119 * Floor  W1  mover slow  -  -   up to nhEF
  2575. 128 * Floor  WR  mover slow  -  -   up to nhEF
  2576.  18   Floor  S1  mover slow  -  -   up to nhEF
  2577.  69   Floor  SR  mover slow  -  -   up to nhEF
  2578.  22   Floor  W1& mover slow  -  TX  up to nhEF
  2579.  95   Floor  WR& mover slow  -  TX  up to nhEF
  2580.  20   Floor  S1& mover slow  -  TX  up to nhEF
  2581.  68   Floor  SR& mover slow  -  TX  up to nhEF
  2582.  47   Floor  G1& mover slow  -  TX  up to nhEF
  2583.   5   Floor  W1  mover slow  -  -   up to LIC
  2584.  91   Floor  WR  mover slow  -  -   up to LIC
  2585. 101   Floor  S1  mover slow  -  -   up to LIC
  2586.  64   Floor  SR  mover slow  -  -   up to LIC
  2587.  24   Floor  G1  mover slow  -  -   up to LIC
  2588. 130 * Floor  W1  mover turbo -  -   up to nhEF
  2589. 131 * Floor  S1  mover turbo -  -   up to nhEF
  2590. 129 * Floor  WR  mover turbo -  -   up to nhEF
  2591. 132 * Floor  SR  mover turbo -  -   up to nhEF
  2592.  56   Floor  W1& mover slow  -  -   up to LIC - 8, CRUSH
  2593.  94   Floor  WR& mover slow  -  -   up to LIC - 8, CRUSH
  2594.  55   Floor  S1  mover slow  -  -   up to LIC - 8, CRUSH
  2595.  65   Floor  SR  mover slow  -  -   up to LIC - 8, CRUSH
  2596.  58   Floor  W1  mover slow  -  -   up 24
  2597.  92   Floor  WR  mover slow  -  -   up 24
  2598.  15   Floor  S1& mover slow  -  TX  up 24
  2599.  66   Floor  SR& mover slow  -  TX  up 24
  2600.  59   Floor  W1& mover slow  -  TXP up 24
  2601.  93   Floor  WR& mover slow  -  TXP up 24
  2602.  14   Floor  S1& mover slow  -  TX  up 32
  2603.  67   Floor  SR& mover slow  -  TX  up 32
  2604. 140 * Floor  S1  mover med   -  -   up 512
  2605.  30   Floor  W1  mover slow  -  -   up ShortestLowerTexture
  2606.  96   Floor  WR  mover slow  -  -   up ShortestLowerTexture
  2607.  38   Floor  W1  mover slow  -  -   down to LEF
  2608.  23   Floor  S1  mover slow  -  -   down to LEF
  2609.  82   Floor  WR  mover slow  -  -   down to LEF
  2610.  60   Floor  SR  mover slow  -  -   down to LEF
  2611.  37   Floor  W1  mover slow  -  NXP down to LEF
  2612.  84   Floor  WR  mover slow  -  NXP down to LEF
  2613.  19   Floor  W1  mover slow  -  -   down to HEF
  2614. 102   Floor  S1  mover slow  -  -   down to HEF
  2615.  83   Floor  WR  mover slow  -  -   down to HEF
  2616.  45   Floor  SR  mover slow  -  -   down to HEF
  2617.  36   Floor  W1  mover fast  -  -   down to HEF + 8
  2618.  71   Floor  S1  mover fast  -  -   down to HEF + 8
  2619.  98   Floor  WR  mover fast  -  -   down to HEF + 8
  2620.  70   Floor  SR  mover fast  -  -   down to HEF + 8
  2621.   9   Floor  S1  mover slow  -  NXP donut (see note 12 above)
  2622.  
  2623. STAIRS
  2624.   8   Stair  W1  mover slow  -  -   stairs
  2625.   7   Stair  S1  mover slow  -  -   stairs
  2626. 100 * Stair  W1  mover turbo -  -   stairs (each up 16 not 8) + crush
  2627. 127 * Stair  S1  mover turbo -  -   stairs (each up 16 not 8) + crush
  2628.  
  2629. MOVING FLOORS
  2630.  53   MvFlr  W1& lift  slow  3  -   start moving floor
  2631.  54   MvFlr  W1& -     -     -  -   stop moving floor
  2632.  87   MvFlr  WR& lift  slow  3  -   start moving floor
  2633.  89   MvFlr  WR& -     -     -  -   stop moving floor
  2634.  
  2635. CRUSHING CEILINGS
  2636.   6   Crush  W1& crush med   0  -   start crushing, fast hurt
  2637.  25   Crush  W1& crush med   0  -   start crushing, slow hurt
  2638.  73   Crush  WR& crush slow  0  -   start crushing, slow hurt
  2639.  77   Crush  WR& crush med   0  -   start crushing, fast hurt
  2640.  57   Crush  W1& -     -     -  -   stop crush
  2641.  74   Crush  WR& -     -     -  -   stop crush
  2642. 141 * Crush  W1& none? slow  0  -   start crushing, slow hurt "Silent"
  2643.  
  2644. EXIT LEVEL
  2645.  11   Exit  nS-  clunk -     -  -   End level, go to next level
  2646.  51   Exit  nS-  clunk -     -  -   End level, go to secret level
  2647.  52   Exit  nW-  clunk -     -  -   End level, go to next level
  2648. 124 * Exit  nW-  clunk -     -  -   End level, go to secret level
  2649.  
  2650. TELEPORT
  2651.  39   Telpt  W1m tport -     -  -   Teleport
  2652.  97   Telpt  WRm tport -     -  -   Teleport
  2653. 125 * Telpt  W1m tport -     -  -   Teleport monsters only
  2654. 126 * Telpt  WRm tport -     -  -   Teleport monsters only
  2655.  
  2656. LIGHT
  2657.  35   Light  W1  -     -     -  -   0
  2658. 104   Light  W1  -     -     -  -   LE (light level)
  2659.  12   Light  W1  -     -     -  -   HE (light level)
  2660.  13   Light  W1  -     -     -  -   255
  2661.  79   Light  WR  -     -     -  -   0
  2662.  80   Light  WR  -     -     -  -   HE (light level)
  2663.  81   Light  WR  -     -     -  -   255
  2664.  17   Light  W1  -     -     -  -   Light blinks (see [4-9-1] type 3)
  2665. 138 * Light  SR  clunk -     -  -   255
  2666. 139 * Light  SR  clunk -     -  -   0
  2667. +
  2668. UDS [4-3-2] Linedef Types
  2669. UDS, Contents
  2670. =
  2671. UDS [4-4] SIDEDEFS
  2672. =
  2673. A sidedef is a definition of what wall texture(s) to draw along a LINEDEF, and a group of sidedefs outline the space of a SECTOR. 
  2674. There will be one sidedef for a line that borders only one sector (and it must be the RIGHT side, as noted in [4-3]). It is not necessary to define what the doom player would see from the other side of that line because the doom player can't go there. The doom player can only go where there is a sector.
  2675. Each sidedef's record is 30 bytes, comprising 2 <short> fields, then 3 <8-byte string> fields, then a final <short> field:
  2676. $3
  2677. (1) X offset for pasting the appropriate wall texture onto the wall's "space": positive offset moves into the texture, so the left portion gets cut off (# of columns off left side = offset).  Negative offset moves texture farther right, in the wall's space.
  2678. (2) Y offset: analogous to the X, for vertical.
  2679. (3) "upper" texture name: the part above the juncture with a lower ceiling of an adjacent sector.
  2680. (4) "lower" texture name: the part below a juncture with a higher floored adjacent sector.
  2681. (5) "middle" texture name: the regular part of the wall. Also known as "normal" or "full" texture.
  2682. (6) SECTOR that this sidedef faces or helps to surround.
  2683. $0
  2684. The texture names are from the TEXTURE1/2 resources. The names of wall patches in the directory (between P_START and P_END) are not directly used, they are referenced through the PNAMES lump.
  2685. Simple sidedefs have no upper or lower texture, and so they will have "-" instead of a texture name. Also, two-sided lines can be transparent, in which case "-" means transparent (no texture).
  2686. If the wall is wider than the texture to be pasted onto it, then the texture is tiled horizontally. A 64-wide texture will be pasted at 0, 64, 128, etc., unless an X-offset changes this.
  2687. If the wall is taller than the texture, than the texture is tiled vertically, with one very important difference: it starts new tiles ONLY at 128, 256, 384, etc. So if the texture is less than 128 high, there will be junk filling the undefined areas, and it looks ugly.  This is sometimes called the "Tutti Frutti" effect.
  2688.  
  2689. There are some transparent textures which can be used as middle textures on 2-sided sidedefs (between sectors). These textures need to be composed of a single patch (see [8-4]), and note that on a very tall wall, they will NOT be tiled. Only one will be placed, at the spot determined by the "lower unpegged" flag being on/off and the sidedef's y offset. And if a transparent texture is used as an upper or lower texture, then the good old "Tutti Frutti" effect will have its way.
  2690. Also note that animated wall textures (see [8-4-1]) do NOT animate if they are the "middle" texture on a 2-sided line. So much for the lava waterfall with the hidden room at its base...hmm, maybe not...
  2691. +
  2692. UDS, Contents
  2693. =
  2694. UDS [4-5] VERTEXES
  2695. =
  2696. These are the beginning and end points for LINEDEFS and SEGS. Each vertice's record is 4 bytes in 2 <short> fields:
  2697.  
  2698. (1) X coordinate
  2699. (2) Y coordinate
  2700.  
  2701. On the automap within the game, with the grid on (press 'G'), the lines are 128 apart (0x80), two lines = 256 (0x100).
  2702. A note on the coordinates: the coordinate system used for the vertices and the heights of the sectors corresponds to pixels, for purposes of texture-mapping. So a sector that's 128 high, or a multiple of 128, is pretty typical, since many wall textures are 128 pixels high.
  2703. And yes, the correct spelling of the plural of "vertex" is "vertices".
  2704. +
  2705. UDS, Contents
  2706. =
  2707. UDS [4-6] SEGS
  2708. =
  2709. The SEGS are stored in a sequential order determined by the SSECTORS, which are part of the NODES recursive tree.
  2710. Each seg is 12 bytes in 6 <short> fields:
  2711. $3
  2712. (1) start of seg is VERTEX with this number
  2713. (2) end VERTEX
  2714. (3) angle: 0= east, 16384=north, -16384=south, -32768=west.  In hex, it's 0000=east, 4000=north, 8000=west, c000=south.  This is also know as BAMS for Binary Angle Measurement.
  2715. (4) LINEDEF that this seg goes along
  2716. (5) direction: 0 if the seg goes the same direction as the linedef it is on, 1 if the seg goes the opposite direction. This is the same as (0 if the seg is on the RIGHT side of the linedef) or (1 if the seg is on the LEFT side of the linedef).
  2717. (6) offset: distance along the linedef to the start of this seg (the vertex in field 1). The offset is in the same direction as the seg. If field 5 is 0, then the distance is from the "start" vertex of the linedef to the "start" vertex of the seg. If field 5 is 1, then the offset is from the "end" vertex of the linedef to the "start" vertex of the seg. So if the seg begins at one of the two endpoints of the linedef, this offset will be 0.
  2718. $0
  2719. For diagonal segs, the offset distance can be obtained from the formula DISTANCE = SQR((x2 - x1)^2 + (y2 - y1)^2). The angle can be calculated from the inverse tangent of the dx and dy in the vertices, multiplied to convert PI/2 radians (90 degrees) to 16384. And since most arctan functions return a value between -(pi/2) and (pi/2), you'll have to do some tweaking based on the sign of (x2-x1), to account for segs that go "west".
  2720. +
  2721. UDS, Contents
  2722. =
  2723. UDS [4-7] SSECTORS
  2724. =
  2725. SSECTOR stands for sub-sector. These divide up all the SECTORS into convex polygons. They are then referenced through the NODES resources.  There will be (number of nodes + 1) ssectors.
  2726. Each ssector is 4 bytes in 2 <short> fields:
  2727.  
  2728. (1) This many SEGS are in this SSECTOR...
  2729. (2) ...starting with this SEG number
  2730.  
  2731. The segs in ssector 0 should be segs 0 through x, then ssector 1 contains segs x+1 through y, ssector 2 containg segs y+1 to z, etc.
  2732. +
  2733. UDS, Contents
  2734. =
  2735. UDS [4-8] NODES
  2736. =
  2737. A detailed explanation of the nodes follows this list of a node's structure in the wad file.
  2738. Each node is 28 bytes in 14 <short> fields:
  2739. $3
  2740. (1)  X coordinate of partition line's start
  2741. (2)  Y coordinate of partition line's start
  2742. (3)  DX, change in X to end of partition line
  2743. (4)  DY, change in Y to end of partition line
  2744. $0
  2745. If (1) to (4) equaled 64, 128, -64, -64, the partition line would go from (64,128) to (0,64).
  2746. $3
  2747. (5)  Y upper bound for right bounding-box.\
  2748. (6)  Y lower bound                    All SEGS in right child of node
  2749. (7)  X lower bound                         must be within this box.
  2750. (8)  X upper bound                        /
  2751. (9)  Y upper bound for left bounding box. \
  2752. (10) Y lower bound                    All SEGS in left child of node
  2753. (11) X lower bound                         must be within this box.
  2754. (12) X upper bound                        /
  2755. (13) a NODE or SSECTOR number for the right child. If bit 15 of this <short> is set, then the rest of the number represents the child SSECTOR. If not, the child is a recursed node.
  2756. (14) a NODE or SSECTOR number for the left child.
  2757. $0
  2758. The NODES lump is by far the most difficult to understand of all the data structures in DOOM. A new level won't display right without a valid set of precalculated nodes, ssectors, and segs.
  2759. Here I will explain what the nodes are for, and how they can be generated automatically from the set of linedefs, sidedefs, and vertices. I am NOT including any code or a pseudo-code algorithm, like I do for the BLOCKMAP (appendix [A-3]). (NOTE: this section was removed)  This is for reasons of space,
  2760. and more importantly, the fact that I haven't written any such algorithm myself. If there's to be some "node code" published here, it will have to be donated by someone, well-commented, well-organized, in pseudo-code, and 100% effective! So the odds are long against it.
  2761.  
  2762. The NODES are branches in a binary space partition (BSP) that divides up the level and is used to determine which walls are in front of others, a process know as hidden-surface removal. The SSECTORS (sub-sectors) and SEGS (segments) lumps are necessary parts of the structure.
  2763. A BSP tree is normally used in 3d space, but DOOM uses a simplified 2d version of the scheme. Basically, the idea is to keep dividing the map into smaller spaces until each of the smallest spaces contains only wall segments which cannot possibly occlude (block from view) other walls in its own space. The smallest, undivided spaces will become SSECTORS. Each wall segment is part or all of a linedef (and thus a straight line), and becomes a SEG. All of the divisions are kept track of in a binary tree structure, which is used to greatly speed the rendering process (drawing what is seen). How does this binary tree lead to faster rendering? I have no idea.
  2764. Only the SECTORS need to be divided. The parts of the levels that are "outside" sectors are ignored. Also, only the walls need to be kept track of. The sides of any created ssectors which are not parts of linedefs do not become segs.
  2765. Some sectors do not require any dividing. Consider a square sector.  All the walls are orthogonal to the floor (the walls are all straight up and down), so from any viewpoint inside the square, none of its four walls can possibly block the view of any of the others. Now imagine a sector shaped like this drawing:
  2766. $2$J
  2767. $p+------.----+  $PThe * is the viewpoint, looking ->, east. The
  2768. $p|       .   |  $Pdiagonal wall marked @ @ can't be seen at all,
  2769. $p|       /\  |@ $Pand the vertical wall marked @@@ is partially
  2770. $p| *->  / @\ |@ $Poccluded by the other diagonal wall. This sector
  2771. $p|     /   @\|@ $Pneeds to be divided. Suppose the diagonal wall
  2772. $p+----/         $Pis extended, as shown by the two dots:
  2773. $0now each of the two resulting sub-sectors are sufficient, because while in either one, no wall that is part of that sub-sector blocks any other.
  2774. In general, being a convex polygon is the goal of a ssector. Convex means a line connecting any two points that are inside the polygon will be completely contained in the polygon. All triangles and rectangles are convex, but not all quadrilaterals. In doom's simple Euclidean space, convex also means that all the interior angles of the polygon are less than or equal to 180 degrees.
  2775. Now, an additional complication arises because of the two-sided linedef. Its two sides are in different sectors, so they will end up in different ssectors too. Thus every two-sided linedef becomes two segs (or more), or you could say that every sidedef becomes a seg. Creating segs from sidedefs is a good idea, because the seg can then be associated with a sector. Two segs that aren't part of the same sector cannot possibly be in the same ssector, so further division is required of any set of segs that aren't all from the same sector.
  2776. Whenever a division needs to be made, a SEG is picked, somewhat arbitrarily, which along with its imaginary extensions, forms a "knife" that divides the remaining space in two (thus binary). This seg is the partition line of a node, and the remaining spaces on either side of the partition line become the right and left CHILDREN of the node. All partition lines have a direction, and the space on the "right" side of the partition is the right child of the node; the space on the "left" is the left child (there's a cute sketch in [4-3]: LINEDEFS that shows how right and left relate to the start and end of a line). Note that if there does not exist a seg in the remaining space which can serve as a partition line, then there is no need for a further partition, i.e. it's a ssector and a "leaf" on the node tree.
  2777. If the "knife" passes through any lines/segs (but not at vertices), they are split at the intersection, with one part going to each child. A two-sided linedef, which is two segs, when split results in four segs. A two sider that lies along an extension of the partition line has each of its two segs go to opposite sides of the partition line. This is the eventual fate of ALL segs on two-sided linedefs.
  2778. As the partition lines are picked and the nodes created, a strict ordering must be maintained. The node tree is created from the "top" down. After the first division is made, then the left child is divided, then its left child, and so on, until a node's child is a ssector. Then you move back up the tree one branch, and divide the right child, then its left, etc. ALWAYS left first, on the way down.
  2779. Since there will be splits along the way, there is no way to know ahead of time how many nodes and ssectors there will be at the end. And the top of the tree, the node that is created first, is given the highest number. So as nodes and ssectors are created, they are simply numbered in order from 0 on up, and when it's all done (nothing's left but ssectors), then ALL the numbers, for nodes and ssectors, are reversed. If there's 485 nodes, then 485 becomes 0 and 0 becomes 485.
  2780. Here is another fabulous drawing which will explain everything. + is a vertex, - and | indicate linedefs, the . . indicates an extension of a partition line. The <, >, and ^ symbols indicate the directions of partition lines. All the space within the drawing is actual level space, i.e. sectors.
  2781. $!$2$t$i
  2782.       +-----+------+-----+           0
  2783.       |     |      |     |         /   \
  2784.       |  e  |^  f  |^ g  |       1       4
  2785.       |     |4     |5    |     /   \    / \
  2786. +-----+ . . +------+-----+    2     3  e   5
  2787. |     |          < 0     |   / \   / \    / \
  2788. |  c  |      b           |  a   b c   d  f   g
  2789. |     |^                 |
  2790. | . . |2. . . . .+-------+  $PThe order in which$p
  2791. |     |          |1 >       $Pthe node tree's$p
  2792. |  c  |^    d    |          $Pelements get made.$p
  2793. |     |3         |          $P0 = node$p
  2794. +-----+----------+          $Pa = ssector$p
  2795. $!$2$t$i
  2796.       0                    (5)
  2797.     /   \      ==>        /   \
  2798.       1       4            (4)     (1)
  2799.     /   \    / \          /   \    / \
  2800.    2     3  e   5       (3)   (2) 2  (0)
  2801.   / \   / \    / \      / \   / \    / \
  2802.  a   b c   d  f   g    6   5 4   3  1   0
  2803. $P
  2804.  The order in which            How the elements
  2805.  the node tree's                are numbered when
  2806.  elements get made.            it's finished.
  2807.  0 = node                        (5) = node
  2808.  a = ssector                     6 = ssector
  2809.  
  2810.  
  2811. $0
  2812.   1. Make segs from all the linedefs. There are 5 two-sided lines here.
  2813.   2. Pick the vertex at 0 and go west (left). This is the first partition line. Note the . . extension line.
  2814.   3. Pick the vertex at 1, going east. The backwards extension . . cuts the line 3>2>, and the unlabeled left edge line. The left edge was one seg, it becomes two. The 3>2> line was two segs, it becomes four. New vertices are created at the intersection points to do this.
  2815.   4. Pick the (newly created) vertex at 2. Now the REMAINING spaces on both sides of the partition line are suitable for ssectors. The left one is first, it becomes a, the right b. Note that ssector a has 3 segs, and ssector b has 5 segs. The . . imaginary lines are NOT segs.
  2816.   5. Back up the tree, and take 1's right branch. Pick 3. Once again, we can make 2 ssectors, c and d, 3 segs each. Back up the tree to 0.
  2817.   6. Pick 4. Now the left side is a ssector, it becomes e. But the right side is not, it needs one more node. Pick 5, make f and g.
  2818.   7. All done, so reverse all the ordination of the nodes and the ssectors. Ssector 0's segs become segs 0-2, ssector 1's segs become segs 3-7, etc. The segs are written sequentially according to the ssector numbering.
  2819.  
  2820. If we want to create an algorithm to do the nodes automatically, it needs to be able to pick partition lines automatically. From studying the original maps, it appears that they usually chose a linedef which divides the child's space roughly in "half". This is restricted by the
  2821. availability of a seg in a good location, with a good angle. Also, the "half" refers to the total number of ssectors in any particular child, which we have no way of knowing when we start! Optimization methods are probably used, or maybe brute force, trying every candidate seg until the "best" one is found.
  2822. What is the best possible choice for a partition line? Well, there are apparently two goals when creating a BSP tree, which are partially exclusive. One is to have a balanced tree, i.e. for any node, there are about the same total number of sub-nodes on either side of it. The other goal is to minimize the number of "splits" necessary, in this case, the number of seg splits needed, along with the accompanying new vertices and extra segs. Only a very primitive and specially constructed set of linedefs could avoid having any splits, so they are inevitable. It's just that with some choices of partition lines, there end up being fewer splits. For example,
  2823. $2
  2824. $p+-----------+    $P If a and b are chosen as partition lines,
  2825. $p|           |    $P there will be four extra vertices needed,
  2826. $p+--+     +--+ < A$P and this shape becomes five ssectors and
  2827. $p   |^   ^|       $P 16 segs. If A and B are chosen, however,
  2828. $p+--+a   b+--+ < B$P there are no extra vertices, and only three
  2829. $p|           |    $P ssectors and 12 segs.
  2830. $p+-----------+       
  2831. $0
  2832. I've read that for a "small" number of polygons (less than 1000?), which is what we're dealing with in a doom level, one should definitely try to minimize splits, and not worry about balancing the tree. I can't say for sure, but it does appear that the original levels strive for this. Their trees are not totally unbalanced, but there are some parts where many successive nodes each have a node and a ssector as children (this is unbalanced). And there are a lot of examples to prove that the number of extra segs and vertices they create is very low compared to what it could be. I think the algorithm that id Software used tried to
  2833. optimize both, but with fewer splits being more important.
  2834. +
  2835. UDS, Contents
  2836. =
  2837. UDS [4-9] SECTORS
  2838. =
  2839. A SECTOR is a horizontal (east-west and north-south) area of the map where a floor height and ceiling height is defined. It can have any shape. Any change in floor or ceiling height or texture requires a new sector (and therefore separating linedefs and sidedefs). If you didn't already know, this is where you find out that DOOM is in many respects still a two-dimensional world, because there can only be ONE floor height in each sector. No buildings with two floors, one above the other, although fairly convincing illusions are possible.
  2840. Each sector's record is 26 bytes, comprising 2 <short> fields, then 2 <8-byte string> fields, then 3 <short> fields:
  2841. $3
  2842. (1) Floor is at this height for this sector
  2843. (2) Ceiling height
  2844. (3) name of the flat used for the floor texture, from the directory.
  2845. (4) name of the flat used for the ceiling texture.  All the flats in the directory between F_START and F_END work as either floors or ceilings. 
  2846. (5) lightlevel of this sector: 0 = total dark, 255 (0xff) = maximum  light. There are actually only 32 brightnesses possible (see COLORMAP [8-2]), so 0-7 are the same, ..., 248-255 are the same.
  2847. (6) special sector: see [4-9-1] immediately below.
  2848. (7) a "tag" number corresponding to LINEDEF(s) with the same tag number. When that linedef is activated, something will usually happen to this sector - its floor will rise, the lights will go out, etc. See [4-3-2] for the list of linedef effects.
  2849. +
  2850. UDS [4-9-1] Special Sector Types
  2851. /
  2852. UDS, Contents
  2853. =
  2854. UDS [4-9-1] Special Sector Types
  2855. =
  2856. Bytes 22-23 of each Sector record are a <short> which determines some area-effects called special sectors.
  2857. Light changes are automatic. The brightness level will alternate between the light value specified for the special sector, and the lowest value amongst adjacent sectors (two sectors are adjacent if a linedef has a sidedef facing each sector). If there is no lower light value, or no adjacent sectors, then the "blink" sectors will instead alternate between 0 light and their own specified light level. The "oscillate" special (8) does nothing if there is no lower light level.
  2858. "blink off" means the light is at the specified level most of the time, and changes to the lower value for just a moment. "blink on" means the light is usually at the lower value, and changes to the sector's value for just a moment. Every "synchronized" blinking sector on the level will change at the same time, whereas the unsynchonized blinking sectors change independently. "oscillate" means the light level goes smoothly from the lower to the higher and back; it takes about 2 seconds to go from maximum to minimum and back (255 down to 0 back up to 255).
  2859. The damaging sector types only affect players, monsters suffer no ill effects from them whatsoever. Players will only take damage when they are standing on the floor of the damaging sector. "-10/20%" means that the player takes 20% damage at the end of every second that they are in the sector, except at skill 1, they will take 10% damage. If the player has armor, then the damage is split between health and armor.
  2860. $3
  2861. Dec Hex Class   Condition or effect
  2862.  0  00  -       Normal, no special characteristic.
  2863.  1  01  Light   random off
  2864.  2  02  Light   blink 0.5 second
  2865.  3  03  Light   blink 1.0 second
  2866.  4  04  Both    -10/20% health AND light blink 0.5 second
  2867.  5  05  Damage  -5/10% health
  2868.  7  07  Damage  -2/5% health
  2869.  8  08  Light   oscillates
  2870.  9  09  Secret  a player must stand in this sector to get credit for finding this secret. This is for the SECRETS ratio on inter-level screens.
  2871. 10  0a  Door    30 seconds after level start, ceiling closes like a door.
  2872. 11  0b  End     -10/20% health. If a player's health is lowered to less than 11% while standing here, then the level ends! Play proceeds to the next level. If it is a final level (levels 8 in DOOM 1, level 30 in DOOM 2), the game ends!
  2873. 12  0c  Light   blink 0.5 second, synchronized
  2874. 13  0d  Light   blink 1.0 second, synchronized
  2875. 14  0e  Door    300 seconds after level start, ceiling opens like a door.
  2876. 16  10  Damage  -10/20% health
  2877. $0
  2878. The following value can only be used in versions 1.666 and up, it will cause an error and exit to DOS in version 1.2 and earlier:
  2879. $3
  2880. 17  11  Light   flickers on and off randomly
  2881. $0
  2882. All other values cause an error and exit to DOS. This includes these two values which were developed and are quoted by id as being available, but are not actually implemented in DOOM.EXE (as of version 1.666):
  2883. $3
  2884.  6  06  -       crushing ceiling
  2885. 15  0f  -       ammo creator
  2886. $0
  2887. What a shame! The "ammo creator" sounds especially interesting!
  2888. +
  2889. UDS, Contents
  2890. =
  2891. UDS [4-10] REJECT
  2892. =
  2893. The REJECT lump is used to help speed play on large levels. It can also be used for some special effects like monsters in plain sight who CANNOT attack or see players.
  2894. The size of a REJECT in bytes is (number of SECTORS ^ 2) / 8, rounded up. It is an array of bits, with each bit controlling whether monsters in a given sector can detect and/or attack players in another sector.
  2895. Make a table of sectors vs. sectors, like this:
  2896. $u
  2897.            sector that the player is in        
  2898.             0  1  2  3  4 
  2899.            ---------------
  2900.             0  1  0  0  0 | 0    sector  
  2901.             1  0  1  1  0 | 1    that    
  2902.             0  1  0  1  0 | 2    the     
  2903.             0  1  1  1  0 | 3    monster 
  2904.             0  0  1  0  0 | 4    is in   
  2905.  
  2906. $UA 1 means the monster cannot become activated by seeing a player, nor can it attack the player. A 0 means there is no restriction. All non-deaf monsters still become activated by weapon sounds that they hear (including the bare fist!). And activated monsters will still pursue the player, but they will not attack if their current sector vs. sector bit is "1". So a REJECT that's set to all 1s gives a bunch of pacifist monsters who will follow the player around and look menacing, but never actually attack.
  2907. How the table turns into the REJECT resource:
  2908. Reading left-to-right, then top-to-bottom, like a page, the first bit in the table becomes bit 0 of byte 0, the 2nd bit is bit 1 of byte 0, the 9th bit is bit 0 of byte 1, etc. So if the above table represented a level with only 5 sectors, its REJECT would be 4 bytes:
  2909. $u
  2910. 10100010 00101001 01000111 xxxxxxx0 (hex A2 29 47 00, decimal 162 41 71 0)
  2911. $U
  2912. In other words, the REJECT is a long string of bits which are read from least significant bit to most significant bit, according to the lo-hi storage scheme used in a certain "x86" family of CPUs. 
  2913. Usually, if a monster in sector A can't detect a player in sector B, then the reverse is true too, thus if sector8/sector5 is set, then sector5/sector8 will be set also. Same sector prohibitions, e.g. 0/0, 3/3, etc. are only useful for special effects (pacifist monsters), or for tiny sectors that monsters can't get to anyway.
  2914.  
  2915. The REJECT array was designed to speed the monster-detection process. If a sector pair is prohibited, the game engine doesn't even bother checking line-of-sight feasibility for the monster to "see" the player and consider attacking. When a level has hundreds of monsters and hundreds of sectors, a good REJECT can prevent the drastic slowdowns that might otherwise occur (even fast CPUs can fall victim to this phenomenon).
  2916. +
  2917. UDS, Contents
  2918. =
  2919. UDS [4-11] BLOCKMAP
  2920. =
  2921. The BLOCKMAP is a pre-calculated structure that the game engine uses to simplify collision-detection between moving things and walls. If a level doesn't have a blockmap, it will display fine, but everybody walks through walls, and no one can hurt anyone else.
  2922. A concise definition of the BLOCKMAP is in appendix [A-1]. This is the full explanation of it.
  2923. The whole level is cut into "blocks", each is a 128 (hex 80) wide square (the grid lines in the automap correspond to these blocks). The BLOCKMAP is a collection of lists, one list for each block, which say what LINEDEFS are wholly or partially in that block (i.e. part of the line passes through the block). When the game engine needs to check for an object/wall collision (to prevent a player from walking through a wall or to explode a rocket when it hits a wall, etc.), it just looks up the blocklist for the block that the object is in. This tells it which linedefs it needs to check for collisions. Most blocks will have few if any lines in them, so there will be a substantial savings in processor time if it only checks a couple linedefs per object instead of a thousand or so linedefs per object - it would have to check every single linedef on the level if not for these blocklists.
  2924. The blocks are also used for object/object collisions, but that is not visible in the WAD format. During play, each block is also given a dynamic "thing list", which tells what THINGS are currently in that block. Again, this negates the need to check every moving object vs. every other object for collisions - only a few need be tested.
  2925. The BLOCKMAP is composed of three parts: the header, the offsets, and the blocklists.
  2926. The 8-byte header contains 4 short integers:
  2927. $u
  2928. (1)     X coordinate of block-grid origin
  2929. (2)     Y coordinate of block-grid origin
  2930. (3)     # of columns (blocks in X direction)
  2931. (4)     # of rows (blocks in Y direction)
  2932. $U
  2933. The block-grid origin is the bottom-left corner of the bottom-left (southwest) block. id's blockmap builder this origin point at 8 less than the minimum values of x and y achieved in any vertex on the level.
  2934. The number of columns and rows needs to be sufficient to contain every linedef in the level. If there are linedefs outside the blockmap, it will not be able to prevent monsters or players from crossing those linedefs, which can cause problems, including the hall of mirrors effect.
  2935.  
  2936. There are N blocks, N = (number of columns * number of rows). Each block has a blocklist and an offset to that blocklist. Immediately following the 8-byte header are N unsigned short integers. The first is the offset in short-ints NOT bytes, from the start of the BLOCKMAP lump to the start of the first blocklist. The last offset points to blocklist (N-1), the last blocklist. Note that all these offsets are UNSIGNED, so they can point to a location 65535 shorts (131070 bytes) into the BLOCKMAP. If they were signed, they could only go up to 32767.
  2937. The blocks are numbered going east (right) first, then north (up). Block 0 is at the southwest corner (row 0, column 0). Block 1 is at row 0, column 1. If there are 37 columns, then block 38 is at row 1, column 0, etc.
  2938.  
  2939. After the offsets come the blocklists. Each blocklist starts with a short-int 0 (0x0000) and ends with a short-int -1 (0xffff). In between are the numbers of every linedef which has any portion whatsoever in the 128 x 128 coordinate area of that block. If the block-grid origin is at (0,0), then the first column is X = 0 to 127 inclusive, the second column is X = 128 to 255 inclusive, etc. So a vertical line with X = 128 which might seem to be on the border of two columns of blocks is actually only in the easternmost/rightmost column. Likewise for the rows.
  2940. The first linedef in the LINEDEFS lump is linedef number 0, and so on. An "empty" block's blocklist only has the two shorts 0 and -1. A non- empty block might have this as its blocklist: 0 330 331 333 -1. This means that linedefs 330, 331, and 333 have some part of them pass through this block. A block that has linedef 0 in it will go: 0 0 .. etc .. -1.
  2941.  
  2942. There is an upper limit to how big a BLOCKMAP can be. Even empty blocklists require at least 3 shorts - the 0, the -1, and the offset to the blocklist. The offsets are unsigned shorts, which would imply a maximum value of short #65535 ( = byte 131070) for the start of the last blocklist. At a little over 6 bytes per blocklist, that would be a maximum of around 21000 blocks (145 by 145 blocks, 18560 in coordinates). But the actual limit is less. Experiments suggest that the maximum total size of all the blocklists, not counting the offsets, is 65535 bytes. This limits a minimalist level to around 120 blocks square (15360 in coordinates), or a realistically complex level to around 100 blocks square (12800 in coordinates).
  2943. +
  2944. UDS, Contents
  2945. =============
  2946. UDS [5] Graphics
  2947. =============
  2948. The great majority of the entries in the directory reference lumps that are in a special picture format. The same format is used for the sprites (monsters, items), the wall patches, and various miscellaneous pictures for the status bar, menu text, inter-level map, etc. Every one of these picture lumps contains exactly one picture. The flats (floor and ceiling pictures) are NOT in this format, they are raw data; see chapter [6].
  2949. A great many of these lumps are used in sprites. A "sprite" is the picture or pictures necessary to display any of the THINGS. Some of them are simple, a single lump like SUITA0. Most of the monsters have 50 or more lumps.
  2950. The first four letters of these lumps are the sprite's "name". TROO is for imps, BKEY is for the blue key, and so on. See [4-2-1] for a list of them all. The fifth letter in the lump is an indication of what "frame" it is, for animation sequences. The letters correspond to numbers, ASCII "A" equalling 0, "B" is 1, ... "Z" is 25, etc. The highest needed by a DOOM 1 sprite is W=22, but some of the DOOM 2 monsters need a few more frames.
  2951. The "0" in the lump name is for "rotations" or "rot"s. All the static objects like torches and barrels and dead bodies look the same from any angle. This is because they have a "rot=0 lump" as DOOM itself might say. Monsters and projectiles look different from different angles. This is done with rots 1-8. This diagram shows how rot 1 is for the front and they go counter-clockwise (looking from above) to 8:
  2952. $p$u
  2953.     3
  2954.       4 | 2
  2955.        \|/
  2956.      5--+----> 1   $PThing is facing this direction$p
  2957.        /|\
  2958.       6 | 8
  2959.     7
  2960. $0
  2961. Many things have sets of lumps like this: TROOA1, TROOA2A8, TROOA3A7, TROOA4A6, TROOA5, TROOB1, etc. This means that for frame 0 (A), the pairs of rots/angles (2 and 8), (3 and 7), and (4 and 6) are mirror- images. In the long run, this saves space in the wad file, and from the designer's point of view, it's 37% fewer pictures to have to draw. 
  2962. If a sprite's frame has a non-zero rot, it needs to have ALL 8 of them. Also note that no more than two rots can be squeezed into one lump's name. Some other two-rot lumps with a different format are shown in the SPIDA1D1, SPIDA2D2, etc. lumps.
  2963.  
  2964. IMPORTANT: Sprite lumps and flats cannot be added or replaced via pwads unless they ALL are. That is, ALL sprites' lumps must be located in a single wad file, and ALL flats' lumps must be in a single wad file. Wall patches CAN be used in external wads, because the PNAMES lump gives a number to every pname, and is used as a quick-index list to load in wall patches.
  2965. Version 1.666 was rumored to be able to include sprites in pwads (in fact the README says it can), but it can't.
  2966. +
  2967. UDS [5-1] Picture Format
  2968. /
  2969. UDS, Contents
  2970. =
  2971. UDS [5-1] Picture Format
  2972. =
  2973. Each picture has three sections. First, an 8-byte header composed of four short-integers. Then a number of long-integer pointers. Then the picture's pixel/color data. See [A-1] for concise BNF style definitions, here is a meatier explanation of the format:
  2974.  
  2975. (A) The header's four fields are:
  2976. $u
  2977. (1) Width. The number of columns of picture data.
  2978. (2) Height. The number of rows.
  2979. (3) Left offset. The number of pixels to the left of the center; where the first column gets drawn.
  2980. (4) Top offset. The number of pixels above the origin; where the top row is.
  2981. $U
  2982. The width and height define a rectangular space or limits for drawing a picture within. To be "centered", (3) is usually about half of the total width. If the picture had 30 columns, and (3) was 10, then it would be off-center to the right, especially when the player is standing right in front of it, looking at it. If a picture has 30 rows, and (4) is 60, it will appear to "float" like a blue soul-sphere. If (4) equals the number of rows, it will appear to rest on the ground. If (4) is less than that for an object, the bottom part of the picture looks awkward.
  2983. With walls patches, (3) is always (columns/2)-1, and (4) is always (rows)-5. This is because the walls are drawn consistently within their own space (There are two integers in each SIDEDEF which can offset the starting position for drawing a wall's texture within the wall space).
  2984.  
  2985. Finally, if (3) and (4) are NEGATIVE integers, then they are the absolute coordinates from the top-left corner of the screen, to begin drawing the picture, assuming the VIEW is full-screen (i.e., the full 320x200). This is only done with the picture of the player's current weapon - fist, chainsaw, bfg9000, etc. The game engine scales the picture down appropriately if the view is less than full-screen.
  2986.  
  2987. (B) After the header, there are N = field (1) = <width> = (# of columns) 4-byte <long> integers. These are pointers to the data for each COLUMN. The value of the pointer represents the offset in bytes from the first byte of the picture lump.
  2988.  
  2989. (C) Each column is composed of some number of BYTES (NOT integers), arranged in "posts":
  2990.  
  2991. The first byte is the row to begin drawing this post at. 0 means whatever height the header (4) upwards-offset describes, larger numbers move correspondingly down.
  2992. The second byte is how many colored pixels (non-transparent) to draw, going downwards. 
  2993. Then follow (# of pixels) + 2 bytes, which define what color each pixel is, using the game palette. The first and last bytes AREN'T drawn, and I don't know why they are there. Probably just leftovers from the creation process on the NeXT machines. Only the middle (# of pixels in this post) are drawn, starting at the row specified in the first byte of the post.
  2994. After the last byte of a post, either the column ends, or there is another post, which will start as stated above.
  2995. 255 (0xFF) ends the column, so a column that starts this way is a null column, all "transparent". Draw the next column.
  2996. +
  2997. UDS, Contents
  2998. =============
  2999. UDS [6] Flats (Floor and Ceiling Textures)
  3000. =============
  3001. All the lumpnames for flats are in the directory between the F_START and F_END entries. Calling them flats is a good way to avoid confusion with wall textures. There is no look-up or meta-structure in flats as there is in walls textures. Each flat is 4096 raw bytes, making a square 64 by 64 pixels. This is pasted onto a floor or ceiling with the same orientation as the automap would imply, i.e. the first byte is the color at the NW corner, the 64th byte (byte 63, 0x3f) is the NE corner, etc.
  3002. The blocks in the automap grid are 128 by 128, so four flats will fit in each block. Note that there is no way to offset the placement of flats, as can be done with wall textures. They are pasted according to grid lines 64 apart, reckoned from the coordinate (0,0). This allows flats to flow smoothly even across jagged boundaries between sectors with the same floor or ceiling height.
  3003.  
  3004. As discussed in chapter [5], replacement and/or new-name flats don't work right from pwad files unless they are all in the same wad. 
  3005. Theoretically, you can change all the flats want by constructing a new DOOM.WAD or ALLFLATS.WAD pwad, but you have to make sure no floor or ceiling uses an entry name which isn't in your F_ section. And you have to include these four entries for DOOM 1 use, although you can change their actual contents (pictures): FLOOR4_8, SFLR6_1, MFLR8_4, and FLOOR7_2. The first three are needed as backgrounds for the episode  end texts. The last is what is shown "outside" the border of the display window if the display is not full-screen.
  3006. +
  3007. UDS [6-1] Animated Floors, see [8-4-1]
  3008. /
  3009. UDS, Contents
  3010. =
  3011. UDS [6-1] Animated Floors, see [8-4-1]
  3012. =
  3013. See Chapter [8-4-1] for a discussion of how the animated walls and flats work. Unfortunately, the fact that the flats all need to be lumped together in one wad file means that its not possible to change the animations via a pwad file, unless it contains ALL the flats, which amounts to several hundred k. Plus it is illegal to distribute the original data, so to pass around modifications, either all the flats must be all-new, or a utility must be used to construct a FLATS.WAD on an end-user's hard drive, using the original DOOM.WAD plus the additions. (Note: Bernd Kreimeier, listed in [A-5], has written a utility that does just this. It is called DMADDS11).
  3014. +
  3015. UDS, Contents
  3016. =============
  3017. UDS [7] Sounds and Music
  3018. =============
  3019. +
  3020. UDS [7-1] PC speaker sound effects (DP*)
  3021. /
  3022. UDS [7-2] Soundcard sound effects (DS*)
  3023. /
  3024. UDS [7-3] songs (D_*)
  3025. /
  3026. UDS [7-4] midi mapping (GENMIDI)
  3027. /
  3028. UDS [7-5] Gravis UltraSound patch mappings (DMXGUS)
  3029. /
  3030. =
  3031. UDS [7-1] PC speaker sound effects (DP*)
  3032. =
  3033. DP* entries in the directory refer to lumps that are sound data for systems using the PC speaker.
  3034. It's a quick and simple format. First is a <short> that's always 0, then a <short> that's the number of bytes of sound data, then follow that many bytes worth of sound data. That is, the lump's bytes will be 0, 0, N, 0, then N bytes of data. The DP* lumps range in size from around 10 bytes to around 150 bytes, and the data seem to range from 0 to 96 (0x00 to 0x60). The numbers obviously indicate frequency, but beyond that I don't know the exact correlation in Hz, nor the time duration of each byte worth of data. Feel free to figure this out and tell me.
  3035. +
  3036. UDS, Contents
  3037. =
  3038. UDS [7-2] Soundcard sound effects (DS*)
  3039. =
  3040. DS* entries in the directory refer to lumps that are sound data for systems using soundcards.
  3041. This data is in a RAW format for 8-bit 11 KHz mono sound - first is an 8-byte header composed of 4 unsigned short integers: 
  3042.  
  3043. (1) 3           (means what?)
  3044. (2) 11025       (the sample rate, samples per second)
  3045. (3) N           (the number of samples)
  3046. (4) 0
  3047.  
  3048. Each sample is a single byte, since they are 8-bit samples. The maximum number of samples is 65535, so at 11 KHz, a little less than 6 seconds is the longest possible sound effect.
  3049. +
  3050. UDS, Contents
  3051. =
  3052. UDS [7-3] songs (D_*)
  3053. =
  3054. D_* entries is the directory refer to lumps that are music. This music is in the MUS file format, which goes like this:
  3055. $3
  3056. offset  type    contents
  3057. 0       ASCII   "MUS" and CTRL-Z (hex 4d 55 53 1a)
  3058. 4      <short>  # of bytes of music data
  3059. 6      <short>  # of bytes of header data (offset to start of music)
  3060. 8      <short>  number of primary channels
  3061. 10     <short>  number of secondary channels
  3062. 12     <short>  number of instrument patches
  3063. 14     <short>  0
  3064. 16     <short>s instrument patch numbers
  3065. X to end  ?     Music data
  3066. $0
  3067. X is the header size (the second short). Drum patch numbers (greater than 128) are 28 less than the numbers listed in the DMXGUS lump.
  3068. What the exact format of the music data is, I don't know.
  3069. +
  3070. UDS, Contents
  3071. =
  3072. UDS [7-4] midi mapping (GENMIDI)
  3073. =
  3074. This has something to do with General MIDI, obviously. This lump has 3 sections: an 8-byte header (the ASCII text "#OPL_II#"), then 150 36-byte records (1 for each instrument), then 150 32-byte strings (names of instruments, padded with zeros). Perhaps the 36 bytes contain waveform information for the General MIDI standard instruments (this guess is based on exactly one glance at a dump of the byte values, so don't put too much faith in it).
  3075. +
  3076. UDS, Contents
  3077. =
  3078. UDS [7-5] Gravis UltraSound patch mappings (DMXGUS)
  3079. =
  3080. This lump is used to do instrument patch mappings on the Gravis Ultra-Sound soundcard. It's in a very simple format - ASCII text! Here's the start and end of the DMXGUS lump from DOOM 1 version 1.2, which is 200 lines, of which the first 10 are comments:
  3081. $u$i$t
  3082. #Purpose: Different size patch libraries for different memory sizes.
  3083. #      The libraries are built in such a way as to leave 8K+32bytes
  3084. #      after the patches are loaded for digital audio.
  3085. #
  3086. #Revision History: 06/22/93 - Fixed problem with 512K patch library
  3087. #          07/26/93 - patch names changed in various releases
  3088. #
  3089. #
  3090. #Explanation of Columns: Patch #  256K  512K  768K  1024K  Patch..
  3091. #
  3092. 0, 2, 1, 1, 1, acpiano
  3093. 1, 2, 1, 1, 1, britepno
  3094. 2, 2, 1, 1, 1, synpiano
  3095. .
  3096. .
  3097. .
  3098. 213, 128, 128, 128, 128, castinet
  3099. 214, 128, 128, 128, 128, surdo1
  3100. 215, 128, 128, 128, 128, surdo2
  3101. +
  3102. UDS, Contents
  3103. =============
  3104. UDS [8] Miscellaneous Lumps
  3105. =============
  3106. +
  3107. UDS [8-1] palettes (PLAYPAL)
  3108. /
  3109. UDS [8-2] colormaps (COLORMAP)
  3110. /
  3111. UDS [8-3] dos exit text (ENDOOM)
  3112. /
  3113. UDS [8-4] texture composition list (TEXTURE1 and TEXTURE2)
  3114. /
  3115. UDS [8-5] wall patch "number for name" indexing list (PNAMES)
  3116. /
  3117. UDS [8-6] demos (DEMO1, DEMO2, and DEMO3)
  3118. /
  3119. UDS, Contents
  3120. =============
  3121. UDS [8-1] palettes (PLAYPAL)
  3122. =============
  3123. There are 14 palettes here, each is 768 bytes = 256 rgb triples. That is, the first three bytes of a palette are the red, green, and blue portions of color 0. And so on. Note that the values use the full range (0..255), while standard VGA digital-analog converters use values 0-63.
  3124. The first palette, palette 0, is used for most situations.   Palettes 10-12 are used (briefly) when an item is picked up, the more items that are picked up in quick succession, the brighter it gets, palette 12 being the brightest.
  3125. Palette 13 is used while wearing a radiation suit.
  3126. Palettes 3, 2, then 0 again are used after getting berserk strength.
  3127. If the player is hurt, then the palette shifts up to number X, then comes "down" one every second or so, to palette 2, then palette 0 (normal) again. What X is depends on how badly the player got hurt: Over 100% damage (add health loss and armor loss), X=8. 93%, X=7. 81%, X=6. 55%, X=5. 35%, X=4. 16%, X=2. These are just rough estimates based on a single test session long ago. Why bother tracking down the exact division points?
  3128.  
  3129. Unknown: what palettes 1 and 9 are for.
  3130. +
  3131. UDS, Contents
  3132. =============
  3133. UDS [8-2] colormaps (COLORMAP)
  3134. =============
  3135. This contains 34 sets of 256 bytes, which "map" the colors "down" in brightness. Brightness varies from sector to sector. At very low brightness, almost all the colors are mapped to black, the darkest gray, etc. At the highest brightness levels, most colors are mapped to their own values, i.e. they don't change.
  3136. In each set of 256 bytes, byte 0 will have the number of the palette color to which original color 0 gets mapped.
  3137. The colormaps are numbered 0-33. Colormaps 0-31 are for the different brightness levels, 0 being the brightest (light level 248-255), 31 being the darkest (light level 0-7). Light level is the fifth field of each SECTOR record, see [4-9].
  3138. Colormap 32 is used for every pixel in the display window (but not the status bar), regardless of sector brightness, when the player is under the effect of the "Invulnerability" power-up. This colormap is all whites and greys.
  3139. Colormap 33 is all black for some reason.
  3140. While the light-amplification goggles power-up is in effect, everything in the display uses colormap 0, regardless of sector brightness.
  3141. +
  3142. UDS, Contents
  3143. =============
  3144. UDS [8-3] dos exit text (ENDOOM)
  3145. =============
  3146. When you finally have to leave DOOM, you exit to dos, and a colorful box of text appears. This is it. It is 4000 bytes, which are simply stored in the screen memory area for 80x25 16-color text mode. Thus it follows the same format as screen memory does: each character on the screen takes up two bytes. The second byte of each pair is from the (extended) ASCII character set, while the first byte of each pair is the color attribute for that character. The color attribute can be explained thus:
  3147. $u
  3148. $p$i$T bit 7    6   5   4   3   2   1   0
  3149. ` +-----+---+---+---+---+---+---+---+
  3150. ` |     |   |   |   |   |   |   |   |
  3151. ` |Blink| Background|  Foreground   |
  3152. ` |     |   |   |   |   |   |   |   |
  3153. ` +-----+---+---+---+---+---+---+---+
  3154. $P$U
  3155. So the foreground color can be from 0-15, the background color can be from 0-7, and the "blink" attribute is either on or off. All this very low-level info can be found in many ancient PC programming books, but otherwise it might be hard to locate...
  3156. +
  3157. UDS, Contents
  3158.  
  3159. =============
  3160. UDS [8-4] texture composition list (TEXTURE1 and TEXTURE2)
  3161. =============
  3162. These are lists of wall texture names used in SIDEDEFS lumps. Each wall texture is composed of one or more wall patches, whose names are listed in the PNAMES lump. But in a texture, the wall patches are not referred to by name, rather by the index number indicating what position they occupy in the PNAMES lump.
  3163. The TEXTURE2 lump is only present in the registered DOOM.WAD. The TEXTURE1 lump is identical in DOOM.WAD and the shareware DOOM1.WAD, and it only refers to pname numbers up to 163, because the shareware wad only has the first 163 wall patches, not all 350.
  3164.  
  3165. A TEXTURE lump starts with a 4-byte long integer N which is the number of textures defined in it. Following it are N long integers which are the offsets in bytes from the beginning of the TEXTURE lump to the start of each texture's definition.
  3166. Then there are N texture definitions, which have the following format. The first (texture name) field is an 8-byte string (less than 8 byte names are padded with zeros), the rest of the fields are 2-byte short integers:
  3167. $3
  3168. (1) The name of the texture, used in SIDEDEFS, e.g. "FIREWALL".
  3169. (2) always 0.
  3170. (3) always 0.
  3171. (4) total width of texture
  3172. (5) total height of texture
  3173.  
  3174. $T$IThe fourth and fifth fields define a "space" (usually 128 by 128 or 64 by 72 or etc...) in which individual wall patches are placed to form the overall picture. To tile vertically on a very tall wall without exhibiting the "Tutti Frutti" effect, a texture must have height 128, the maximum. There is no maximum width.
  3175. $3      
  3176. (6) always 0.
  3177. (7) always 0.
  3178. (8) Number of 5-field (5 <short>) patch descriptors that follow. This means that each texture entry has variable length. Many entries have just 1 patch, the most used in DOOM in a single texture is 64.
  3179. $0
  3180. Patch descriptor:
  3181. $3
  3182. (a) x offset from top-left corner of texture space defined in fields 4 and 5 to start placement of this patch
  3183. (b) y offset
  3184. (c) number (0...) of the entry in the PNAMES lump that contains the lump name from the directory, of the wall patch to use...
  3185. (d) always 1, is for something called "stepdir"...
  3186. (e) always 0, is for "colormap"...
  3187. $0
  3188. Each texture's entry ends after the last of its patch descriptors.   Note that patches can have transparent parts, since they are in the same picture format as everything else. Thus there can be (and are) transparent wall textures. These should only be used on a border between two sectors, to avoid "hall of mirrors" problems.
  3189. Also, textures intended for use as the "middle" texture of a 2-sided SIDEDEF (e.g. transparent textures) should only be composed of a single patch. A limitation in the game engine will cause the "medusa" effect if there is more than 1 patch in any middle texture that is visible in the display window. This effect causes the computer to slow to a crawl and make play impossible until the offending wall is out of view.
  3190. +
  3191. UDS [8-4-1] Animated Walls
  3192. /
  3193. UDS [8-4-2] The SKY Textures
  3194. /
  3195. UDS, Contents
  3196. =============
  3197. UDS [8-4-1] Animated Walls
  3198. =============
  3199. Some of the walls and floors are animated. In the case of wall textures, it is possible to substantially customize these animations. Flats' animations can theoretically also be modified, but since flats don't work from pwads, that can make the effort very difficult.
  3200. The game engine sets up a number of wall animation cycles based on what entries it finds in the TEXTURE lumps. It also sets up flat animations based on what lumps exist between F_START and F_END. Versions before 1.666 can have up to 9 animated walls and 5 animated flats. Version 1.666 (DOOM 1 or 2) can have 13 walls and 9 floors animate.
  3201. For wall animations, the entries in the columns "First" and "Last" below, and all the entries between them (in the order that they occur in the TEXTURE lump) are linked. If one of them is listed as a texture on a sidedef, that sidedef will change texture to the next in the cycle about 3 times a second, going back to <First> after <Last>. Flats work similarly, except the order is dictated by the wad directory. If both of the <First> and <Last> texture/flat names are not present, no problem. Then that potential cycle is unused. But if <First> is present, and <Last> either is not present or is listed BEFORE <First>, then an
  3202. error occurs while the DOOM operating system sets up, and it aborts.
  3203. Note that much longer sequences are possible! The entries between <First> and <Last> can be almost anything; they need not be the same in number as in the original, nor do they have to follow the same naming pattern. Thus one could set up SLADRIP1, TRON2, TRON3, TRON4, ..., TRON67, SLADRIP3 for a 69-frame animated wall!
  3204. The "Ver" column indicates what version of DOOM is required. "All" indicates all versions have it. The "r" signifies that the shareware DOOM1.WAD does not contain the necessary picture lumps. The "2" means that only DOOM 2 has the necessary picture lumps, but version 1.666 of DOOM.EXE for DOOM 1 also has the capability to use these animation-cycle names (for pwad designers).
  3205. $2
  3206. First       Last         Ver    Normal # of frames
  3207. BLODGR1     BLODGR4       r     4
  3208. BLODRIP1    BLODRIP4      r     4
  3209. FIREBLU1    FIREBLU2      r     2
  3210. FIRELAV3    FIRELAVA      r     2 (3 patches are in DOOM.WAD, 1 is unused)
  3211. FIREMAG1    FIREMAG3      r     3
  3212. FIREWALA    FIREWALL      r     3
  3213. GSTFONT1    GSTFONT3      r     3
  3214. ROCKRED1    ROCKRED3      r     3
  3215. SLADRIP1    SLADRIP3     All    3
  3216.  
  3217. BFALL1      BFALL4        2     4
  3218. SFALL1      SFALL4        2     4
  3219. WFALL1      WFALL4        2     4
  3220. DBRAIN1     DBRAIN4       2     4
  3221.  
  3222. (floor/ceiling animations):
  3223. NUKAGE1     NUKAGE3      All    3
  3224. FWATER1     FWATER4       r     4
  3225. SWATER1     SWATER4       -     4 (SWATER lumps aren't in any DOOM.WAD)
  3226. LAVA1       LAVA4         r     4
  3227. BLOOD1      BLOOD3        r     3
  3228. RROCK05     RROCK08       2     4
  3229. SLIME01     SLIME04       2     4
  3230. SLIME05     SLIME08       2     4
  3231. SLIME09     SLIME12       2     4
  3232. +
  3233. UDS, Contents
  3234. =============
  3235. UDS [8-4-2] The SKY Textures
  3236. =============
  3237. The SKY1, SKY2, and SKY3 textures are rather special in that they are used as sky backgrounds when the player is out in the open. They can also be used on regular walls, but they usually aren't, because then they just look like a painting. The "background" effect is done by the game engine. There is a special flat, F_SKY1, which is used to indicate that a floor or ceiling is "transparent" to the SKY beyond. The picture data in the F_SKY1 flat is not even used.
  3238. Upper textures between F_SKY1 ceilinged sectors do not have the specified texture (if any) drawn. Instead, they are "sky". Likewise with lower textures between F_SKY1 floored sectors, but it doesn't work as well, because if the player's viewpoint is below the top of
  3239. a lower-texture-sky (i.e. if any part of it is in the upper half of the display), it causes a hall-of-mirrors effect.
  3240. SKY textures as sky backgrounds are mirror-images of what they look like on walls.
  3241. The SKY textures are always placed with their tops at the top of the view window. Since they cannot be more than 128 high, just like any other texture, a rather ugly "seam" in the sky is sometimes visible if the player can see too far "down".
  3242. SKY textures do move horizontally, though, to give a realistic effect. Doing a complete 360 degree turn will scroll by a 256-wide SKY four times. A 1024-wide SKY will exactly circumscribe the horizon. The 0 column of the SKY texture will be at due north (as on the automap), the 256 column is at west, 512 is south, and 768 is east. So the middle part of a 256-wide SKY is visible at NW, SW, SE, and NE.
  3243.  
  3244. SKY textures can be composed of several patches, just like regular textures, but trying to animate the sky doesn't work. DOOM.EXE can be changed so that SKY2 is the start of an animation cycle, and indeed on a wall it will animate, but the sky background does not. This is perhaps related to the way that "middle" textures of sidedefs do not animate.
  3245. +
  3246. UDS, Contents
  3247. =============
  3248. UDS [8-5] wall patch "number for name" indexing list (PNAMES)
  3249. =============
  3250. This is a list of all the names of lumps that are going to be used as wall patches. DOOM assigns numbers to these names, in the order that they are listed. The numbers are then used in TEXTURE1 and TEXTURE2 entries to refer to wall patch lumps. In a texture composition entry, 0 means the first pname, 1 is the second, ...
  3251.  
  3252. The first four bytes of the PNAMES lump is a long integer N.
  3253. Then follow N pnames, each of which occupies 8 bytes. Pnames less than 8 bytes long are padded with zeros. These names duplicate an entry in the directory (but are not case sensitive - lowercase letters will match uppercase letters and vice versa). Unlike sprites and floors, wall patches can be loaded from external pwads. Whichever pwad was listed
  3254. last on the command line and contains a lump with the same name as the one in the PNAMES lump (which itself could be from a pwad) is the pwad that is used to get the picture data for that wall patch.
  3255. +
  3256. UDS, Contents
  3257. =============
  3258. UDS [8-6] demos (DEMO1, DEMO2, and DEMO3)
  3259. =============
  3260. If you start DOOM and do nothing, after a few seconds, it automatically shows a demo of play on some level. Also, external demos can be recorded and played back by using the command line parameters explained in the README and/or the DOOM FAQ. All external demos have a .LMP extension which the DOOM OS attaches; you only type the [demoname] without the .LMP extension.
  3261. The DOOM.WAD lumps DEMO1, DEMO2, and DEMO3 are in exactly the same format as these external LMP files. Strictly speaking, the "demo" format should not be called the "LMP" format, because any external file without a wadfile header, i.e. it is just raw data, is a "lump" and deserves the .LMP extension.
  3262. $2
  3263. A DOOM demo has three parts:
  3264. (1) header - 7 or 13 bytes
  3265. (2) data recording player moves - 4 bytes per player per gametic
  3266. (3) quit byte - equals 128 (0x80)
  3267. (1) There are two different kinds of header depending on the version of
  3268. DOOM used to record the demo. Versions up to 1.2 use a 7-byte header:
  3269.  
  3270.   byte  range   purpose
  3271. 0       0-4     skill level. 0="I'm too young to die", 4="Nightmare!"
  3272. 1       1-3     episode.
  3273. 2       1-9     mission/map.
  3274. 3       0-1     player 1 is present if this is 1.
  3275. 4       0-1     player 2.
  3276. 5       0-1     player 3.
  3277. 6       0-1     player 4.
  3278.  
  3279.  Versions after 1.2 use a 13-byte header:
  3280. byte    range   purpose
  3281. 0       104-106 version. 104=1.4 beta, 105=1.5 beta, 106=1.6 beta or 1.666
  3282. 1       0-4     skill level. 0="I'm too young to die", 4="Nightmare!"
  3283. 2       1-3     episode. In DOOM 2 this is always 1.
  3284. 3       1-32    mission/map/level. In DOOM 1, it's 1-9. In DOOM 2, it's 1-32.
  3285. 4       0-2     mode. 0=single or cooperative, 1=deathmatch, 2=altdeath
  3286. 5       0-      respawn. 0=no respawn parameter, (any other value)=respawn.
  3287. 6       0-      fast. 0=no fast parameter, (any other value)=fast.
  3288. 7       0-      nomonsters. 0=monsters exist, (any other value)=nomonsters.
  3289. 8       0-3     viewpoint. 0=player 1's status bar, ..., 3=player 4.
  3290. 9       0-1     player 1 is present if this is 1.
  3291. 10 0x0a 0-1     player 2.
  3292. 11 0x0b 0-1     player 3.
  3293. 12 0x0c 0-1     player 4.
  3294.  
  3295. (2) The player-move data is recorded in 4-byte chunks. Every 1/35 of a
  3296. second is a gametic, and for every gametic, there is one 4-byte chunk
  3297. per player. So the time duration of a demo (in seconds) is approximately
  3298. equal to its length in bytes divided by (140 * number_of_players).
  3299.  
  3300. The four bytes recording each player's actions are:
  3301. (a) Forward/Backward Movement. 
  3302. (b) Strafe Right/Left Movement.
  3303. (c) Turn Left/Right.
  3304. (d) other actions - use/activate, fire, change weapons.
  3305.  
  3306. The first three are signed bytes (i.e. of type <char>).
  3307.  
  3308. (a) Ranges from -127 to 127, negative numbers are backward movement, positive numbers are forward movement. Without the -turbo option above 100, values outside -50..50 cannot be achieved. With a keyboard or joystick, these are the regular values:
  3309.  
  3310. Move forward:   25 (0x19)   with Speed on:  50 (0x32)
  3311. Move backward: -25 (0xE7)   with Speed on: -50 (0xCE)
  3312.  
  3313. Fancy mouse use can achieve any number in the range.
  3314.  
  3315. (b) Ranges from -127 to 127, negative numbers are left-strafe movement, positive numbers are right-strafe movement. The keyboard values are:
  3316.  
  3317. Strafe right: 24  (0x18)    with Speed on:  50 (0x32)
  3318. Strafe left: -24  (0xE8)    with Speed on: -50 (0xCE)
  3319.  
  3320. (c) Ranges from -127 to 127, negative numbers are right turns, positive numbers are left turns. The keyboard values vary from version to version, but are all in the range -5..5, and that's with Speed on.
  3321. Using the mouse can achieve much higher numbers here. I doubt if the maximums of 127 and -127 can actually be achieved in play, though.
  3322.  
  3323. (d) the bits of this byte indicate what actions the player is engaged in:
  3324.    bit 0     Fire current weapon
  3325.    bit 1     Use (a switch, open a door, etc.)
  3326.    bit 2     Change weapon to the one indicated in bits 3-5:
  3327.    bits 5-3 = 000 Fist or Chainsaw
  3328.          001 Pistol
  3329.          010 Shotgun
  3330.          011 Chaingun
  3331.          100 Rocket Launcher
  3332.          101 Plasma Rifle
  3333.          110 BFG 9000
  3334.          111 Super Shotgun (DOOM 2 only)
  3335.     bit 6     unused
  3336.     bit 7     indicates a special action which alters the meanings of the other bits:
  3337.         bits 1-0 = 01 pause or unpause
  3338.              = 10 save game in slot # recorded in bits 4 to 2 (slot number can thus be 0 to 7 but should NOT be 6 or 7 or else!)
  3339.  
  3340. There might be other special actions. The save game action happens during replay of the demo, so be careful when playing demos if you have important savegames! One or more of them could conceivably get
  3341. overwritten.
  3342.  
  3343. (3) The last byte of a demo has the value 128 (0x80)
  3344. +
  3345. UDS [8-6-1] Level changes from 1.2 to 1.666 DOOM.WAD
  3346. /
  3347. UDS, Contents
  3348. =============
  3349. UDS [8-6-1] Level changes from 1.2 to 1.666 DOOM.WAD
  3350. =============
  3351. Many people have experienced the error "Demo from a different game version", because DOOM versions will only play back demos that were recorded with the same version number. Theoretically, though, ANY version can be converted to ANY other version. Versions up to 1.2 don't even require any modification, and versions 1.4 and up just require that their first byte be changed. To change between the two families (pre-1.4 and post-1.2) would just require extra header bytes be added/shaved.
  3352. But there are serious complications to converting demos. There have been some minor changes and bug-fixes to the levels from version to version. Since the demos only record player actions, they have NOTHING about the level in them, so they depend on the level used for playback to be the same as the level used for recording. Some kinds of differences in the playback level can cause the demo to become "unsynchronized" with the level, and players will seem to have gone crazy. For example, if a deathmatch start-position is at a different location, when a demo-player is spawned there, they will try to open doors that don't exist at the new location, shoot at people who aren't there, etc. The entire playback is ruined from that point on. Some examples of changes that don't matter are different floor and wall textures, light levels, and linedef "unpegged" flags. But most changes DO matter. 
  3353. Note that changes like (nomonsters) vs. (monsters), (respawn) vs. (regular), (altdeath) vs. (regular deathmatch) will very quickly lead to unsynchronized goofball players.
  3354. +
  3355. UDS, Contents
  3356. =============
  3357. UDS [9] Savegame Files
  3358. =============
  3359. (no text?)
  3360. +
  3361. UDS, Contents
  3362. =============
  3363. UDS [10] The DOOM.EXE File
  3364. =============
  3365. Via pwads, a great many characteristics of the DOOM environment can be changed: maps, pictures, sounds, etc. But there are also a lot of neat things that can be done by patching the DOOM.EXE file itself. There is a large collection of data at the end of the EXE file, and by patching some bytes, we can turn literal values into variables. For example, the player has a 16-unit "radius" which prevents him from entering very small passageways. The player's radius can be made 1 and his "height" 1, so he can enter mouse-sized crawlspaces. There are a lot more exciting examples, such as invisible monsters, cyber-demons that look like players, super-fast shotguns, and a hundred others, but I won't describe all of that here. See appendix [A-4] for some EXE utilities and documents. Here I will simply give the data that has been figured out to date.
  3366. I freely mix hex and decimal numbers below. Hopefully you can tell from the context. All of the stuff below applies to registered version 1.2, and some of it applies to version 1.666 also. This chapter has not yet been completely updated for 1.666, but it soon will be.
  3367. +
  3368. UDS [10-1] Version 1.2 DOOM.EXE Data Segment Overview
  3369. /
  3370. UDS [10-2] Version 1.666 DOOM.EXE Data Segment Overview
  3371. /
  3372. UDS [10-3] Detail on some EXE Data Structures
  3373. /
  3374. UDS, Contents
  3375. =============
  3376. UDS [10-1] Version 1.2 DOOM.EXE Data Segment Overview
  3377. =============
  3378. The data begins at 0x6f414 (455700) and continues to the end of the file, 0x8db27 (580391). Here's an overview of the sections:
  3379. $2
  3380. start length what
  3381. 6f414  3d30  TEXT STRINGS
  3382. 73412  1a34  various unknowns, probably to do with I/O, sound, mouse, etc.
  3383. 74bf8 10000  looks like hard-coded math tables, for speed?
  3384. 84bf8   148  misc.
  3385. 84d40    82  gamma correction messages
  3386. 84dc2   280  "are you sure you want to quit" messages
  3387. 85042   3a2  MENUS (new game, load game, etc.)
  3388. 853e4   140  ?
  3389. 85524   36c  configuration options and defaults, like in DEFAULT.CFG
  3390. 85890   174  ?
  3391. 85a04    60  ?
  3392. 85a64    54  ?
  3393. 85ab8    c4  ?
  3394. 85b7c    20  max ammo at start, and ammo per thing
  3395. 85b9c    c0  ammo type and frame #s for the weapons
  3396. 85c5c   188  ANIMATED WALLS and FLOORS
  3397. 85de4   258  SWITCH-WALLS
  3398. 8603c    c0  ?
  3399. 860fc    d4  ?
  3400. 861d0   500  5 colormaps for use with the gamma correction setting 0-4
  3401. 866e4    fc  ?
  3402. 867e0    40  pointers to chatmacros, "Green:", etc.
  3403. 86820    88  pointers to level names, used on Automap
  3404. 868a8    d8  splat mark coordinates for end-level screen
  3405. 86980   5a8  wimap patch animations for end-level screen
  3406. 86f28   224  SONG NAMES list of pointers
  3407. 8714c   8b8  SOUND TABLE
  3408. 87a04   1a4  SPRITE NAMES list of pointers
  3409. 87ba8  3800  STATE TABLE
  3410. 8b3a8    20  ?
  3411. 8b3c8  2368  THING TABLE
  3412. 8d730   3fd  ?
  3413. +
  3414. UDS, Contents
  3415. =============
  3416. UDS [10-2] Version 1.666 DOOM.EXE Data Segment Overview
  3417. =============
  3418. (no text)
  3419. +
  3420. UDS, Contents
  3421. =============
  3422. UDS [10-3] Detail on some EXE Data Structures
  3423. =============
  3424. More detail on some of the data follows. The "names" of each section are the hexadecimal offsets to the start of that data, in the registered versions 1.2 and 1.666 of DOOM.EXE. 1.2 offsets are to the left of the asterisk, 1.666 to the right. "Integer" means a 4-byte <long> integer in hi-lo format, unless otherwise noted (e.g. "2-byte short integer").
  3425. $u
  3426. 6f414 *** 82a14 
  3427. START OF DATA. Several times I'll refer to "pointers". All of these pointers are integers. Add the values of these pointers to $6f414 or $82a14 depending on the version, and you'll get the location of what's being pointed to.
  3428. Note: there's also at least one other kind of pointer in here, with larger values, that point to a location in the code, NOT the data. I call these "code-pointers" for now. I know it's a lame term.
  3429. 6f414 *** a2228 
  3430. TEXT STRINGS. They all start on 4-byte boundaries, i.e. at xxxx0/4/8/c. $00 ends the string. Then the next one starts at the next boundary, so a 4 byte string is followed by $00, then 3 bytes of random junk, then the next string.
  3431. 73140
  3432. I think this is the last string, "TZ"
  3433. 73144
  3434. Misc. stuff I haven't investigated. Some of it has to do with sound card stuff and mice and joysticks, because at 7384c is "DMXGUS.INI" and at 74ba8 are pointers which point to the strings "None", "PC_Speaker", "Adlib", etc. 
  3435. 74bf8
  3436. 64k of precisely ordered numbers, which leads me to believe they are pre-calculated math tables, to speed up some floating point operations used in the screen draw routine. Any other guesses?
  3437. 84bfc
  3438. 3 pointers to the episode 1/2/3 end texts, "Once you beat...", "You've done it...", and "The loathsome Spiderdemon is dead..."
  3439. 84c24
  3440. pointer to the string "doom.wad"
  3441. 84c74
  3442. pointer to the string "default.cfg"
  3443. 84c78
  3444. 8 integers: 1, 25, 50, 24, 40, 640, 1280, 320
  3445. 84c98
  3446. 2 code-pointers
  3447. 84ccc
  3448. 29 integers, with values like 90 and 135 and 180. Angles?
  3449. 84d40
  3450. "Gamma correction OFF", 00s, "Gamma correction level 1", ... 4. Each occupies $1a bytes.
  3451. 84dc2
  3452. 8 text messages used to confirm quitting, each uses $50 bytes
  3453. 85042
  3454. MENUS. I know this controls to some extent which menu pictures are used for which menu, but I haven't figured it all out yet.
  3455. 853e4
  3456. 14 ints: 42, 22, 23, 24, 28, 29, 31, 40, zeros
  3457. 8541c
  3458. 256 bytes, values from 00-ff, no two the same, "random" order.
  3459. 85524
  3460. The configuration options. Each is 5 integers: a pointer to a string, like "mouse_sensitivity", a code-pointer, the default value for that option, a 0 or 1 (1 for all the "key_" options), and a 0. It would be pretty dense to do anything with this, I think.
  3461. 85890
  3462. About 117 integers, with a definite structure, but I can't figure it out, and changing/experimenting seems to do nothing.
  3463. 85a64
  3464. 21 sets of 4 bytes: 0, 0, 1, 0, 320, 168, "33", 0, 1, $(b2 26 26 2e), $(ff 63 fd ff), a pointer that points to the $(b2...), 0, 1, "ema", 0, 0, 1, 0, 1, "xma". All these are unchanged from version 0.99 through 1.2, except the pointer obviously.
  3465. 85ab8
  3466. Ints: 0, -1, -1, 0, 0, 0, 0, 4, 7, 10, 12, 14, 15, 15, 0, 0, 112, 96, 64, 176, then 16 that are members of this set {-65536, -47000, 0, 47000, 65536}, then 4, 5, 6, 7, 0, 1, 2, 3, 8, 3, 1, 5, 7
  3467. $!
  3468. 85b7c *** 95714
  3469. AMMO AMOUNTS. 8 integers: 200, 50, 300, 50, 10, 4, 20, 1. The first four are the maximum initial capacity for ammo, shells, cells, and rockets. The backpack doubles these amounts. The second four are how many ammo in a clip, shells, rockets/rocket, and cells/cell item. Boxes have 5x as much.
  3470. 859bc *** 95734
  3471. $t$i$uAMMO TABLE. 8 sets of 6 integers (9 sets in 1.666):
  3472.     version 1.2             version 1.666
  3473.  5  4  3  2  5  0     5  4  3  2  5  0    Punch    
  3474.  0 12 11 10 13 17     0 12 11 10 13 17    Pistol   
  3475.  1 20 19 18 21 30     1 20 19 18 21 30    Shotgun  
  3476.  0 34 33 32 35 38     0 51 50 49 52 55    Chaingun 
  3477.  3 42 41 40 43 46     3 59 58 57 60 63    Laucher  
  3478.  2 59 58 57 60 62     2 76 75 74 77 79    Plasma   
  3479.  2 66 65 64 67 71     2 83 82 81 84 88    BFG      
  3480.  5 53 52 50 54  0     5 70 69 67 71  0    Chainsaw 
  3481.               1 34 33 32 35 47    Super-Shotgun
  3482. $0The first number of each set is the ammo type. Type 5 never runs out. The next three numbers are 3 state #s (see the STATE TABLE below) for the pictures displayed when moving while holding that weapon. You know, the "bobbing weapon" effect? Fifth is the first state of the "shoot" sequence for that weapon, and last is the first state of the "firing" sequence. The "firing" pictures are the ones that are lit up, fire coming out, etc.
  3483. $u
  3484. 85c5c *** 9580c
  3485. ANIMATED WALLS and FLOORS. Each is 26 bytes: an integer, a 8-byte string,
  3486. $00, a 8-byte string, $00, and a final integer.
  3487. 0 NUKAGE3  NUKAGE1  8
  3488. 0 FWATER4  FWATER1  8
  3489. 0 SWATER4  SWATER1  8
  3490. 0 LAVA4    LAVA1    8
  3491. 0 BLOOD4   BLOOD1   8
  3492.                <---- v1.666 has four more:  0 RROCK08  RROCK05  8
  3493. 1 BLODGR4  BLODGR1  8                               0 SLIME04  SLIME01  8
  3494. 1 SLADRIP4 SLADRIP1 8                               0 SLIME08  SLIME05  8
  3495. 1 BLODRIP4 BLODRIP1 8                               0 SLIME12  SLIME09  8
  3496. 1 FIREWALL FIREWALA 8
  3497. 1 GSTFONT3 GSTFONT1 8
  3498. 1 FIRELAVA FIRELAV3 8
  3499. 1 FIREBLU2 FIREBLU1 8
  3500. 1 ROCKRED3 ROCKRED1 8
  3501.                <---- V1.666 has four more:  1 BFALL4   BFALL1   8
  3502.                             1 SFALL4   SFALL1   8
  3503.                             1 WFALL4   WFALL1   8
  3504.                             1 DBRAIN4  DBRAIN1  8
  3505. $0Obviously the 0/1 means floor or wall. The first string is the name of the animation cycle's LAST listed texture, the second string is the FIRST listed texture. The cycle includes them and all entries between them in whichever wad file is in effect (It doesn't have to be DOOM.WAD, a pwad with new TEXTURE1 and 2 resources works quite nicely). The final 8 doesn't seem to mean much.
  3506. 85dc8
  3507. A -1 then a bunch of zeros, maybe space for another animation cycle?
  3508. 85de4 *** 95a64
  3509. SWITCH WALL NAMES. Each is 20 bytes: an 8-byte string, 00, another string, 00, and a 2-byte short integer. There are 28 switch names here in v1.2 and 39 switch names in v1.666. When a switch is pulled, the game checks to see if the wall texture is on this list. If it is, it changes the wall texture to the corresponding alternate texture. The <short> is 1, 2, or 3. 1 means it's in all versions, 2 means only registered DOOM 1 and DOOM 2, 3 means DOOM 2 only.
  3510. 86028
  3511. 20 zeros, again, room for one more?
  3512. 8603c ***
  3513. 48 integers: 3 0 2 1 3 0 2 0 3 1 2 0 0 0 0 0
  3514.            2 0 2 1 0 0 0 0 3 1 3 0 0 0 0 0
  3515.            2 0 3 1 2 1 3 1 2 1 3 0 0 0 0 0
  3516. 860fc ***
  3517. 50 integers, all are either 50 or -50.
  3518. 861d0 ***
  3519. 5 sets of 256 bytes, each is a COLORMAP, for the gamma correction settings OFF, 1, 2, 3, 4.
  3520. 866d0 ***
  3521. 5 integers: 1, 0, -1, 0, 0
  3522. 866e4 ***
  3523. 13 sets of 5 - 10 bytes, each set terminated by a $FF
  3524. 8675e ***
  3525. $74 $20
  3526. 86760 ***
  3527. 13 pointers to the stuff at 866e4. An integer '0' between each pointer.
  3528. 867c8 ***
  3529. 6 integers: -1, -1, 0, -1, 0, 1
  3530. 867e0 ***
  3531. 10 pointers to the 10 default chatmacros, then 4 pointers, to "Green:", "Indigo:", "Brown:", "Red:"
  3532. 86820 ***
  3533. AUTOMAP LEVEL NAMES. 27 pointers to the level names used on the automap.
  3534. 8689c ***
  3535. The ascii letters "gibr" - the keys for sending messages in multiplayer.
  3536. 868a8 ***
  3537. SPLAT MARK COORDINATES. At what screen coordinates to place the WISPLAT picture on the end-level screen, for th 27 levels. 54 integers, 27 pairs. e1m1 x, e1m1 y, ..., e3m9 y.
  3538. 86980, 86bb0, 86da8 ***
  3539. END-LEVEL MAP ANIMATIONS. Each is 14 integers. The first one is (0, 11, 3, 224, 104, 0, 0, 0, 0, 0, 0, 0, 0, 0). The first number is 0 for all the ones on maps 0 and 2 (episodes 1 and 3), and it's 2 for map 1. The 11 is always 11 except the last one of map 2 is 8. The 3 means 3 pictures are involved in the animation, e.g WIA00100, WIA00101, and WIA00102. 224 and 104 are the x and y coordinates. The sixth number is not 0 for map 1 - it's from 1 to 8. This controls the way the Tower of Mystery "appears". All the other numbers are always 0.
  3540. 86ef8 ***
  3541. Three integers, how many animations for WIMAP0, 1, 2 respectively.
  3542. 86f04 ***
  3543. Three pointers, to the starts of the animations for WIMAP0, 1, 2 respectively.
  3544. 8714c ***
  3545. SOUND TABLE. 61 and 1/2 sounds are listed here. Each is 9 integers: a pointer to the string which is the sound's "name", then a 0 or 1, then a value ranging from 32 to 128, then 0, -1, -1, 0, 0, 0. The names are "pistol", "shotgn", ... "hoof", "metal", "chgun". Prefix DS or DP and you get the entries in DOOM.WAD for the sound data. The "chgun" is the 1/2 - there's no "DSCHGUN" in doom.wad, and the entry in this table is incomplete anyway, lacking the all-important 0, -1, -1, 0, 0, 0 ending :-). There seem to be a few glitches in the way the sounds were fit into the whole scheme, this is just one of them. 
  3546. 879ec ***
  3547. pointer to start of SOUND TABLE.
  3548. 879f0 ***
  3549. Integer = 150. 150 whats?
  3550. 87a04 ***
  3551. SPRITE NAME POINTERS. 105 pointers to the strings "TROO", "SHTG", ..., "SMRT".
  3552. 87ba8 *** 9834c
  3553. STATE TABLE. 512 entries in v1.2, 967 entries in v1.666. Each entry is 28 bytes in 7 integers:
  3554. (1)     sprite number 0-..., lookup in sprite name pointers list.
  3555. (2)     sprite frame, 0="A" in a sprite lump, 1="B", etc.
  3556. (3)     duration, how many gametics this state is displayed until it looks for the next. -1 (0xffffffff) is forever.
  3557. (4)     a "code pointer" which indicates what action(s) accompany the displaying of this state.
  3558. (5)     next state in sequence. 0 means no next state, sequence is done.
  3559. (6)     always 0, has no effect.
  3560. (7)     always 0, has no effect.
  3561. 8b3a8 ***
  3562. Two integers: 1, 0, then 6 code-pointers.
  3563. 8b3c8 *** 9ed10
  3564. THING TABLE. 103 entries in v1.2 which are each 88 bytes = 22 integers. 136 entries in v1.666, which are each 92 bytes = 23 integers.
  3565. (1)     Thing number, as used in maps. See [4-2-1]. Some of them are equal to -1, e.g. the players' entry, and all projectiles.
  3566. (2)     "Spawn" state. State number (from STATE TABLE) for when this thing first appears.
  3567. (3)     Health. Inanimates can't be killed, so it doesn't apply to them.
  3568. (4)     "Moving" state. First state # of monsters pursuing, etc.
  3569. (5)     "See player" sound. For monsters who become activated. Also for projectiles' first sound. Note that sounds are 1-..., not 0-...   0 indicates no sound.
  3570. (6)     Reaction Time. Lower is faster.
  3571. (7)     "Attack" sound.
  3572. (8)     "Pain" state.
  3573. (9)     Painchance. The chance out of 256 that a monster will be disrupted when it gets hurt. Otherwise, they keep attacking.
  3574. (10)    "Pain" sound.
  3575. (11)    "Close attack" state.
  3576. (12)    "Distance attack" state.
  3577. (13)    "Death" state, or "explode" for projectiles.
  3578. (14)    "Explosive death" state, only some monsters can be "mushed".
  3579. (15)    "Death" sound, or "explode" for projectiles.
  3580. (16)    Speed of movement. Projectiles' speed are * 65536.
  3581. (17)    Horizontal size (radius) * 65536
  3582. (18)    Height * 65536
  3583. (19)    Mass
  3584. (20)    Missile damage. Also, the Lost Soul has a 3 here, for it's attack.
  3585. (21)    "Act" sound, for wandering monsters.
  3586. (22)    Flags, see below
  3587. (23)    "Respawn" state, for monsters being ressurected. VERSION 1.666 ONLY
  3588.  
  3589.   Flags. 0 = condition is false. 1 = condition is true.
  3590.   bit   flagname        effect on thing
  3591.   0     Special         it is a gettable thing (ammo, health, etc.)
  3592.   1     Solid           creatures can't pass through (but projectiles can)
  3593.   2     Shootable       can be hurt (note barrels have this set)
  3594.   3     NoSector        totally invisible
  3595.   4     NoBlockmap      
  3596.   5
  3597.   6     (InPain)        ?
  3598.   7
  3599.   8     SpawnCeiling    hung from ceiling
  3600.   9     NoGravity       floating monsters and not-on-ground things
  3601.   10    Dropoff         doesn't automatically hug floor if "jump" off ledge
  3602.   11    Pickup          can pick up gettable items
  3603.   12    (NoClip)        walks through walls
  3604.   13
  3605.   14    Float           floating monsters
  3606.   15    (Semi-NoClip)   climb tall steps
  3607.   16    Missile         projectiles
  3608.   17    (Disappearing  ?  Weapon)        
  3609.   18    Shadow          semi-invisible like Spectres
  3610.   19    NoBlood         uses PUFF instead of BLUD when hurt (e.g. barrels)
  3611.   20    (SlideHelpless) ?
  3612.   21
  3613.   22    CountKill       Monster: counts toward KILLS ratio on inter-level
  3614.   23    CountItem       Artifact: counts toward ITEMS on inter-level screen
  3615.   24    (Running)       ?
  3616.   25    NotDMatch       this thing doesn't get spawned in deathmatch modes
  3617.   26    Color0          \ 00 = green stays green  01 = change to dark greys
  3618.   27    Color1          / 10 = change to browns   11 = change to dark reds
  3619.   28-                   unused
  3620. 8d730 *** n/a
  3621. Misc junk I can't figure out.
  3622. 8db27 *** a7b99
  3623. End of DOOM.EXE
  3624. +
  3625. UDS, Contents
  3626. =============
  3627. UDS, APPENDICES
  3628. =============
  3629. +
  3630. UDS [A-1] Backus-Naur Form definitions of wad elements
  3631. /
  3632. UDS [A-2] Engine limits
  3633. /
  3634. UDS [A-3] DOOM.WAD changes and errors
  3635. /
  3636. UDS [A-4] Other helpful documents
  3637. /
  3638. UDS [A-5] Acknowledgments
  3639. /
  3640. UDS, Contents
  3641. =============
  3642. UDS [A-1] Backus-Naur Form definitions of wad elements
  3643. =============
  3644. The descriptions below use a modified Backus-Naur Form (BNF) notation. Each entry looks like
  3645. <keyword>  := description  ;type or comment (optional)
  3646.          description cont'd.  ;type or comment (optional)
  3647.  
  3648. Descriptions composed of more than one sequential keyword or element are usually listed with one element per line. This is for clarity and also allows each succesive element to be assigned different types without extra lines.
  3649. <keyword>       := <whatever>           ;<type>
  3650. is a shorthand for
  3651. <keyword>       := <whatever>
  3652. <whatever>      := <type>
  3653. The description is one or more of the following predefined types, and/or previously or subsequently defined keywords.
  3654. <byte>          is an unsigned 8-bit integer (0 to 255).
  3655. <char>          is a signed 8-bit integer (-128 to 127).
  3656. <ushort>        is an unsigned 16-bit integer in lo-hi format (0 to 65535)
  3657. <short>         is a signed 16-bit integer (-32768 to 32767).
  3658. <long>          is a signed 32-bit integer (-2147483648 to 2147483647).
  3659. <string8>       is an ASCII string of from 1 to 8 bytes. If its length is less than 8 bytes, the remainder are zeros (hex 00).
  3660. Any of these may be followed by a range: <byte:1..99> means a byte restricted to the range 1 to 99 inclusive. A single number means that value is literally included: <byte:192> inserts that 8-bit value.
  3661.      { } are used to enclose a group of elements.
  3662.      | is used to separate choices - exactly one of the choices applies.
  3663.      [ ] are used following an element or group of elements to indicate an array. Usually a literal value or a keyword will be used to denote how many members the array has. <rook> [666] means that the element <rook> is repeated 666 times in sequence. {<Scylla> <Charybdis>} [zeus] means that whatever the value of <zeus> is, there are that many pairs of <Scylla> and <Charybdis>. [1..16] indicates the value may be from 1 to 16 inclusive, and [...] indicates an indefinite number.
  3664. A literal string "ABCD" may appear, in which case those ASCII characters
  3665. are directly inserted.
  3666. ------
  3667. $i$t<WAD file>      := "PWAD"|"IWAD" 
  3668.            <numlumps> 
  3669.            <infotableofs> 
  3670.            <lumps> 
  3671.            <directory>
  3672.  
  3673. <numlumps>      := <long>               ;number of lumps in WAD file
  3674. <infotableofs>  := <long>               ;file offset to directory start
  3675.  
  3676. <lumps>         := <lump> [numlumps]
  3677. <lump>          :=                      ;see different kinds below
  3678.  
  3679. <directory>     := {<lumpinfo> | <otherinfo>} [numlumps]
  3680. <lumpinfo>      := <filepos>            ;<long>
  3681.            <size>               ;<long>
  3682.            <name>               ;<string8>
  3683.  
  3684. <otherinfo>     := <marker> | <label>
  3685. <marker>        := <dummynumber>        ;<long> with any value
  3686.            <long:0>
  3687.            <"S_START" | etc>    ;<string8>
  3688.  
  3689. <label>         := {<"E"> <episode> <"M"> <mission>} | {<"MAP"> <level>}
  3690. <episode>       := "1"|"2"|"3"
  3691. <mission>       := "1"|"2"|"3"|"4"|"5"|"6"|"7"|"8"|"9"
  3692. <level>         := "01"|"02"|"03"|"04"|"05"|"06"|"07"|"08"|"09"|"10"
  3693.            |"11"|"12"|"13"|"14"|"15"|"16"|"17"|"18"|"19"|"20"
  3694.            |"21"|"22"|"23"|"24"|"25"|"26"|"27"|"28"|"29"|"30"
  3695.            |"31"|"32"
  3696.  
  3697. ------
  3698. different kinds of lumps:
  3699. ------
  3700. <PLAYPAL>       := <palette> [14]
  3701. <palette>       := {<red> <green> <blue>} [256]
  3702. <red>           := <byte>
  3703. <green>         := <byte>
  3704. <blue>          := <byte>
  3705.  
  3706. ------
  3707. <COLORMAP>      := <color_map> [34]
  3708. <color_map>     := <mapping> [256]
  3709. <mapping>       := <byte>
  3710.  
  3711. ------
  3712. <ENDOOM>        := <character_cell> [1000]
  3713. <character_cell>:= <color_attributes>           ;<byte>
  3714.            <character>                  ;<byte>
  3715.  
  3716. ------
  3717. <demo>          := <header>
  3718.            <gametic_data>
  3719.            <byte:128>
  3720. <header>        := {<header_12> | <header_16>}  ;different versions
  3721. <header_12>     := <skill>
  3722.            <episode>
  3723.            <map>
  3724.            <player> [4]
  3725. <header_16>     := <version>
  3726.            <skill>
  3727.            <episode>
  3728.            <map> 
  3729.            <mode>
  3730.            <respawn>
  3731.            <fast>
  3732.            <nomonsters>
  3733.            <viewpoint>
  3734.            <player> [4]
  3735. <skill>         := <byte:0..4>
  3736. <episode>       := {<byte:1..3> | <byte:1>}     ;DOOM 1 or DOOM 2
  3737. <map>           := {<byte:1..9> | <byte:1..32>} ;DOOM 1 or DOOM 2
  3738. <player>        := <byte:0..1>          ;0 means not present, 1 means present
  3739. <version>       := <byte:104..106>      ;versions 1.4, 1.5, 1.6 (also 1.666)
  3740. <mode>          := <byte:0..2}          ;cooperative|deathmatch|altdeath
  3741. <respawn>       := <byte>               ;0 is off, non-zero is on
  3742. <fast>          := <byte>               ;0 is off, non-zero is on
  3743. <nomonsters>    := <byte>               ;0 is off, non-zero is on
  3744. <viewpoint>     := <byte:0..3>          ;shown from this player's view
  3745.  
  3746. <gametic_data>  := <gametic> [...]
  3747. <gametic>       := <player_move> [1..4] ;1-4 is # of players present in demo
  3748. <player_move>   := <forward>            ;<char>
  3749.            <strafe>             ;<char>
  3750.            <turn>               ;<char>
  3751.            <use>                ;<byte>
  3752.  
  3753. ------
  3754. <GENMIDI>       := "#OPL_II#"
  3755.            <instr_data> [150]
  3756.            <instr_name> [150]
  3757. <instr_data>    := <byte> [36]          ;format unknown to me
  3758. <instr_name>    := <byte> [32]          ;padded with 0s
  3759.  
  3760. ------
  3761. <DMXGUS>        := pointless to describe here, see section [7-5]
  3762.  
  3763. ------
  3764. <song>          := "MUS"
  3765.            <byte:26>
  3766.            <music_length>       ;<ushort>
  3767.            <music_start>        ;<ushort>
  3768.            <primary_channels>   ;<ushort>
  3769.            <secondary_channels> ;<ushort>
  3770.            <num_instr_patches>  ;<ushort>
  3771.            <ushort:0>
  3772.            <instr_patches>
  3773.            <music data>
  3774. <instr_patches> := <instr_patch> [num_instr_patches]
  3775. <instr_patch>   := <ushort>             ;Drum patch #s 28 less than in DMXGUS
  3776.  
  3777. <music data>    := ???
  3778.  
  3779. ------
  3780. <soundeffect>   := <ushort:3>
  3781.            <ushort:11025>       ;sampling rate
  3782.            <num_samples>        ;<ushort>
  3783.            <ushort:0>
  3784.            <samples>
  3785. <samples>       := <sample> [num_samples]       ;<byte>
  3786.  
  3787. ------
  3788. <PC_sound>      := <ushort:0>
  3789.            <num_PC_samples>     ;<ushort>
  3790.            <PC_samples>
  3791. <PC_samples>    := <PC_sample> [num_PC_samples]
  3792. <PC_sample>     := <byte>               ;seem to range [0..96]
  3793.  
  3794. ------
  3795. <TEXTURE1>      := <num_textures>       ;<long>
  3796.            <tex_offsets>
  3797.            <tex_entries>
  3798. <tex_offsets>   := <tex_offset> [num_textures]
  3799. <tex_offset>    := <long>
  3800. <tex_entries>   := <tex_entry> [num_textures]
  3801. <tex_entry>     := <tex_name>           ;<string8>
  3802.            <short:0>
  3803.            <short:0>
  3804.            <tex_width>          ;<short>
  3805.            <tex_height>         ;<short>
  3806.            <short:0>
  3807.            <short:0>
  3808.            <num_patches>        ;<short>
  3809.            <patches>            
  3810. <patches>       := <patch> [num_patches]
  3811. <patch>         := <x_offset>           ;all are <short>
  3812.            <y_offset>
  3813.            <pname_number>       ;lookup in <PNAMES> for picture
  3814.            <short:1>            ;supposedly <stepdir>
  3815.            <short:0>            ;supposedly <color_map>
  3816.  
  3817. ------
  3818. <PNAMES>        := <num_pnames>         ;<long>
  3819.            <pnames>
  3820. <pnames>        := <pname> [num_pnames]
  3821. <pname>         := <string8>]           ;match the <name> from the
  3822.                     ;<lumpinfo> of a <picture>
  3823.  
  3824. ------
  3825. <picture>       := <header>
  3826.            <pointers>           ;offsets to <column> starts
  3827.            <pixel_data>
  3828. <header>        := <width>              ;all are <short>
  3829.            <height>
  3830.            <left_offset>
  3831.            <top_offset>
  3832. <pointers>      := <pointer> [width]    ;<long>
  3833. <pixel_data>    := <column> [width]
  3834. <column>        := <post> [...] 
  3835.            <byte:255>           ;255 (0xff) ends the column
  3836. <post>          := <rowstart>           ;<byte>
  3837.            <num_pixels>         ;<byte>
  3838.            <unused>             ;<byte>
  3839.            <pixels>
  3840.            <unused>             ;<byte>
  3841. <pixels>        := <pixel> [num_pixels] ;<byte>
  3842.  
  3843. ------
  3844. <flat>          := <colorbyte> [4096]   ;<byte>
  3845.  
  3846. ------
  3847. <maplevel>      := <THINGS> 
  3848.            <LINDEDEFS> 
  3849.            <SIDEDEFS> 
  3850.            <VERTEXES> 
  3851.            <SEGS> 
  3852.            <SSECTORS> 
  3853.            <NODES> 
  3854.            <SECTORS> 
  3855.            <REJECT> 
  3856.            <BLOCKMAP>
  3857.  
  3858. <THINGS>        := <thing> [...]
  3859. <thing>         := <x_position>         ;all are <short>
  3860.            <y_position>
  3861.            <angle>
  3862.            <type>
  3863.            <options>
  3864.  
  3865. <LINEDEFS>      := <linedef> [...]
  3866. <linedef>       := <vertex_start>       ;all are <short>
  3867.            <vertex_end>
  3868.            <flags>
  3869.            <function>
  3870.            <tag>
  3871.            <sidedef_right>
  3872.            <sidedef_left>       ;if <short: -1> there's no left side
  3873.  
  3874. <SIDEDEFS>      := <sidedef> [...]
  3875. <sidedef>       := <xoffset>            ;<short>
  3876.            <yoffset>            ;<short>
  3877.            <uppertexture>       ;<string8>
  3878.            <lowertexture>       ;<string8>
  3879.            <middletexture>      ;<string8>
  3880.            <sector_ref>         ;<short>
  3881.  
  3882. <VERTEXES>      := <vertex> [...]
  3883. <vertex>        := <X_coord>            ;both are <short>
  3884.            <Y_coord>    
  3885.  
  3886. <SEGS>          := <seg> [...]          ;<segs> stored by <subsector> order
  3887. <seg>           := <vertex_start>       ;all are <short>
  3888.            <vertex_end>
  3889.            <bams>
  3890.            <line_num>
  3891.            <segside>
  3892.            <segoffset>
  3893.  
  3894. <SSECTORS>      := <subsector> [...]
  3895. <subsector>     := <numsegs>            ;both are <short>
  3896.            <start_seg>
  3897.  
  3898. <NODES>         := <node> [...]
  3899. <node>          := <x>                  ;first four are <short>
  3900.            <y>
  3901.            <dx>
  3902.            <dy>
  3903.            <bbox> [2]
  3904.            <child> [2]
  3905. <bbox>          := <boxtop>             ;all are <short>
  3906.            <boxbottom>
  3907.            <boxleft>
  3908.            <boxright>
  3909. <child>         := <ushort>             ;if 0x8000 it's a subsector
  3910.  
  3911. <SECTORS>       := <sector> [...]
  3912. <sector>        := <floorheight>        ;<short>
  3913.            <ceilingheight>      ;<short>
  3914.            <floorpic>           ;<string8>
  3915.            <ceilingpic>         ;<string8>
  3916.            <lightlevel>         ;<short>
  3917.            <special_sector>     ;<short>
  3918.            <tag>                ;<short>
  3919.  
  3920. <REJECT>        := <bitarray>           ;see [4-10] for this one
  3921.  
  3922. <BLOCKMAP>      := <xorigin>            ;<short>
  3923.            <yorigin>            ;<short>
  3924.            <xblocks>            ;<short>
  3925.            <yblocks>            ;<short>
  3926.            <listoffsets>
  3927.            <blocklists>
  3928. <listoffsets>   := <listoffset> [numofblocks]
  3929. <listoffset>    := <ushort>
  3930. <numofblocks>   := <short>              ;note it equals <xblocks> * <yblocks>
  3931. <blocklists>    := <blocklist> [numofblocks]
  3932. <blocklist>     := <short: 0>           ;for dynamic thinglist pointer
  3933.            <lines_in_block>
  3934.            <short: -1>
  3935. <lines_in_block>:= <linedef_num> [...]  ;the numbers of all the <linedef>s
  3936.                     ;that are in the block
  3937. <linedef_num>   := <short>
  3938. +
  3939. UDS, Contents
  3940. =============
  3941. UDS [A-2] Engine limits
  3942. =============
  3943. Maximum width of a TEXTURE = NONE?
  3944. Maximum height of a TEXTURE = 128
  3945. Maximum edges in display that can have their sides rendered = 128 in 1.2, 256 in 1.6+
  3946. Maximum blocks in a BLOCKMAP = about 13000, or 113 * 113
  3947. Maximum THINGS in view at once = 64, extras are not drawn
  3948. Maximum patches on a texture used on a 2Sided "middle" texture before "medusa" effect = 1
  3949. Maximum # of "plats" = 30 (up/down moving floors, and lifts)
  3950. Maximum # of "scrolling" walls per level (line type 48) = 64
  3951. +
  3952. UDS, Contents
  3953. =============
  3954. UDS [A-3] DOOM.WAD changes and errors
  3955. =============
  3956. There are some imperfections in the DOOM.WAD file. All versions up to 1.666 have the SW18_7 lump included twice. Versions before 1.666 have the COMP03_8 lump twice. And with version 1.666 somebody really messed up, because every single DP* and DS* and D_* lump that's in the shareware DOOM1.WAD is in the registered DOOM.WAD twice. The error doesn't adversely affect play in any way, but it does take up an unnecessary 800k on the hard drive.
  3957. Some of the lumps in the sprite section are unused. Versions before 1.666 had PBULx0 and PSHEx0, x=A-B, which were pictures of bullet and shell casings being ejected after the player fired a weapon (this feature was obviously removed). Also there were four more "fireball" sprite-lump sets: BAL3x0, BAL4x0, x=A-E, and BAL5x0 and BAL6x0, x=A-B. The only unused lump left in 1.666 is SMT2A0, which is a small grey stalagmite, similar to the SMIT sprite which is THING #47. There are some new sprite lumps in version 1.666 of DOOM 1 which are "semi-unused" because they aren't used in DOOM 1, but they ARE used in DOOM 2. They are all projectile sprites, so it's probably just a little leftover from compiling the WAD.
  3958. So, in case it might help with converting demos, or for any other reason, here is a list, entirely by Paul Falstad, of all the changes to the levels between DOOM 1.2 and DOOM 1.666. The 1.4 and 1.5 beta's levels are in most if not all respects identical to 1.666's - I haven't checked.
  3959.  
  3960. E1M2
  3961. - Linedef #530 changed from a door that closes to one that stays open.  This is the south side of the door out of the maze.  This allows deathmatch players who started in there to get out from the inside.
  3962.  
  3963. E1M4
  3964. - The swastika got changed to a different shape.  A bunch of things in the swastika room got moved around to accomodate the new layout.
  3965. - Thing #185 (a deathmatch start position) got moved from (768, 1952) to (736, 1824).  This is in the room with the ledge NW of the player 1 starting room; the deathmatch start got moved off the ledge onto the main floor.
  3966.  
  3967. E1M5
  3968. - Thing #216 (a deathmatch start) got moved from (-2112, 512) to (-800, 1200); that is, it got moved from the west courtyard (the one with the supercharger) to the hidden hallway just south of the pentagram.
  3969. - Sector #105's floor was lowered from 88 to 80.  In other words, the window west of the yellow keycard was enlarged a bit.  Also, the associated linedefs are no longer marked impassable.
  3970.  
  3971. E1M6
  3972. - Thing #116 (the sargeant in the middle of void space in the southeast corner of the map) got removed.
  3973. - Sectors #139 and #142 got their floor changed from FLOOR0_6 to FLOOR4_8 for consistency with the surrounding sectors.  (These are the floors underneath the yellow doors on the northwest and northeast corners of one of the rooms.)
  3974.  
  3975. E1M7
  3976. - Linedef #782 was type 0; now it's type 31 (door that stays open).  This is south side of the last door before the exit door; it can now be opened from the inside, so a deathmatch player that started in the exit room can get out.
  3977.  
  3978. E1M8
  3979. - The computer map in the pentagram got changed to a shotgun.
  3980. - Linedefs 35, 136, and 140 no longer have their upper textures unpegged.  This is the secret door to the supercharger; it now looks like a real door when it opens.
  3981. - A secret door was added in the east baron's alcove. When you push on the east wall, a secret chamber opens with a switch.  That switch lowers the lift to the south, so that you can get back into the complex. (Though you could anyway, by jumping through the window on the west or east side of the hallway south of the lift...) Actually, it lowers the lift to the lowest adjacent floor, which (after the two barons are dead) is lower than the hallway floor height.  Probably not the intended effect.
  3982. - Vertex #223 got moved ever so slightly NW for some reason.
  3983.  
  3984. E2M4
  3985. - Northwest of the big green "O", there is a secret room with partial invisibility.  The door to the room closes when you walk north through a hallway just southwest of it; you're supposed to shoot the door to open it.  However, if you run north quickly over the trigger line and then run east through the door, you can just make it before the door closes, but in 1.2 you'd be trapped inside, since the door would not open from the east side.  In 1.666, the linedef type of the east edge of the door has been changed so that you can open the door from inside the secret room.
  3986.  
  3987. E3M1
  3988. - Sector 8's trigger number is now 0.  Previously, it was 6, which is the same number as one of the lines you walk over when getting the shotgun.  This line would cause the floor to be lowered.  However, sector 8's floor is already lower than that of any adjacent sectors, so nothing happened.
  3989.  
  3990. E3M4
  3991. - Sidedefs 1327 and 1332 had their texture offsets fixed.  These are the sidedefs on either side of the window between the room with the beserker and the room with two spectres and a teleporter, east of the player one starting point.  Now, the window looks better than it did before, but still not perfect.
  3992.  
  3993. E3M6
  3994. - There is now a BFG9000 sitting in the northwest window in the building which you're facing at the start of the level.  It only appears in multiplayer mode. The structure which has the switch leading to the secret level had its north wall thickened, so that you can't trigger the switch from outside of the structure.
  3995. +
  3996. UDS, Contents
  3997. =============
  3998. UDS [A-4] Other helpful documents
  3999. =============
  4000. There are several other excellent sources of information about DOOM, editing DOOM levels, changing the DOOM.EXE, and pwads. Some of the following items get widely distributed (BBS, Usenet, online services, FTP) and some don't. Three prominent FTP sites with huge quantities of doom-related material are:
  4001.  
  4002.     infant2.sphs.indiana.edu   /pub/doom and subdirectories (../wad_edit/text has most documents)
  4003.     wuarchive.wustl.edu   /pub/msdos_uploads/games/doomstuff
  4004.     ftp.uwp.edu   /pub/incoming/id   /pub/msdos/games/id/home-brew/doom
  4005.  
  4006.   The infant2 site also has a number of mirrors. 
  4007.   As time passes, newer versions of these documents may be released, and/or the file names will change:
  4008.  
  4009. DESIGN12.ZIP    Level Design FAQ, edited by Tom Neff
  4010.           Truly has lots of good questions, and good answers,
  4011.           to common questions related to level design. Covers
  4012.           the simple stuff, and some of the most advanced
  4013.           topics too. Also, it is editor-nuetral, i.e. it
  4014.           does not restrict itself to any single level editor.
  4015.           Highly recommended.
  4016.  
  4017. DMFAQ666.ZIP    The Official DOOM FAQ 6.666 by Hank Leukart.
  4018.           A huge collection of information about the history
  4019.           of DOOM, notes on game play, and lists of add-on
  4020.           utilities available to enhance play. 
  4021.  
  4022. DOOMBSP.ZIP     The source code from id's bsp routines, which build
  4023.           the NODES structure and the REJECT and BLOCKMAP too.
  4024.           If you want to see C, here it is.
  4025.  
  4026. METRICS.ZIP     "DOOM Metrics", by Scott Amspoker. Has some more info
  4027.           and more explanations related to [4-2-2]: Thing Sizes,
  4028.           and how monsters prefer stairs that aren't too steep.
  4029.  
  4030. TEXPATCH.ZIP    Textures To Patches, by Gregory Lewis. Shows the
  4031.           patch composition of every texture in registered
  4032.           DOOM.
  4033.           
  4034. TEXTURES.ZIP    "Managing Textures and the Unpegged Attribute", by
  4035.           Scott Amspoker. Explains in great depth how textures
  4036.           are drawn on walls, how the unpegged flag works, and
  4037.           how texture offsets apply.
  4038.  
  4039. DH200.ZIP       DOOM.EXE Hack Editor, by Greg Lewis. This program
  4040.           allows changes to be made to the DOOM.EXE file and
  4041.           they can be saved/loaded via patch files. The thing
  4042.           and frame tables (discussed in chapter [10]) are the
  4043.           main emphasis of this excellent utility.
  4044.  
  4045. ???             "Fun with Dehacked", edited by Dan Lottero. Has a lot
  4046.           of tips and tricks for using the DOOM.EXE Hack Editor
  4047.           (dehacked).
  4048.  
  4049. ???             "Blackadder's DeHackEd Patch Reviews", by Michael Adcock.
  4050.           Last updated 24Jul94?
  4051.  
  4052. ???             "DOOM Deathmatch Wad Ranking", by James Dicke and Jim
  4053.           Urbas. Is a good system for rating how good and how
  4054.           fun deathmatch play is on pwads. If you want to find
  4055.           the best deathmatch levels, this is a good place to
  4056.           start.
  4057.  
  4058. ???             pwad review documents and lists.
  4059.  
  4060. ???             "The unofficial LMP format description 1.0", by
  4061.           Uwe Girlich
  4062. +
  4063. UDS, Contents
  4064. =============
  4065. UDS [A-5] Acknowledgments
  4066. =============
  4067. The following people either brought mistakes to my attention, or provided additional information that I've incorporated into these specs. Thanks for all the help! Sorry if I left anyone out.  
  4068. If you have any comments or questions, have spotted any errors, or have any possible additions, please send me e-mail. If you've contacted me before, please note my new address (msfell@aol.com).
  4069.  
  4070. id Software
  4071.     Created DOOM, added the -file parameter, used a simple format
  4072.     for the WAD, and occasionaly released specifications and
  4073.     technical information about DOOM and DOOM 2 :-)
  4074.  
  4075. All PWAD designers and doom-utility programmers everywhere!
  4076.  
  4077. Coleman Reed Ammerman (cammer@cs.tamu.edu) and John Wolsh
  4078.     They were the first to document the DEMO format.
  4079.  
  4080. Scott Amspoker (scott@bbx.basis.com)
  4081.     Wrote the METRICS and TEXTURES articles.
  4082.  
  4083. Jeff Bird (jeff@wench.ece.jcu.edu.au)
  4084.     Good ideas about the NODES, and a blockmap algorithm.
  4085.  
  4086. Alistair Brown (A.D.Brown@bradford.ac.uk)
  4087.     Helped me understand the NODES and explained REJECT.
  4088.  
  4089. Frans P. de Vries (fpdevries@hgl.signaal.nl)
  4090.     The cool ASCII DOOM logo used for the header. Also, gave a
  4091.     comprehensive list of typos and mistakes in the 1.3 specs.
  4092.  
  4093. Paul Falstad (pjf@crash.cts.com)
  4094.     I got ALL of the [8-6-1] information from his messages. 
  4095.  
  4096. Robert Fenske (rfenske@swri.edu)
  4097.     Passed along a great linedef flag list. Also helped with linedef
  4098.     types, blockmap, special sectors, and general suggestions.
  4099.  
  4100. Nelson Fernandez Jr. (nelson@netcom.com)
  4101.     Distributed information about savegame files.
  4102.  
  4103. Uwe Girlich (girlich@aix520.informatik.uni-leipzig.de)
  4104.     Wrote "The unofficial LMP format description 1.0"
  4105.  
  4106. Stuart Herbert (ac3slh@sunc.sheffield.ac.uk)
  4107.     Clarifying how pegged/unpegged flags work.
  4108.  
  4109. Herre de Jonge (herre@morra.et.tudelft.nl) 
  4110.     First pointed out the stairs mistake in the 1.3 specs.
  4111.  
  4112. Tom Klok (a344@mindlink.bc.ca)
  4113.     DMXGUS and MUS file format info.
  4114.  
  4115. Bernd Kreimeier (bernd@nero.uni-bonn.de)
  4116.     Wrote DMADDS11. Sprites, savegames, sounds, and lots of other help.
  4117.  
  4118. Steve Larsen (larsen@sunset.cs.utah.edu)
  4119.     Several patches for the DOOM.EXE file
  4120.  
  4121. Hank Leukart (ap641@cleveland.freenet.edu)
  4122.     Edits the DOOM FAQ and distributes these specs!
  4123.  
  4124. Greg Lewis (gregl@umich.edu)
  4125.     Wrote DeHackEd, and gave lots of info on EXE variables.
  4126.  
  4127. Joel Lucsy (jjlucsy@mtu.edu)
  4128.     Info on COLORMAP and PLAYPAL.
  4129.  
  4130. Sean Malloy (malloy@nprdc.navy.mil)
  4131.     Step-by-step proof of exactly how stairs work.
  4132.  
  4133. John A. Matzen (jamatzen@cs.twsu.edu)
  4134.     Instrument names in GENMIDI.
  4135.  
  4136. Steve McCrea (sm@eng.cam.ac.uk)
  4137.     Animated textures and textures larger than 256 wide.
  4138.  
  4139. Brian McKimens (samneric@connected.com)
  4140.     Comprehensive work on linedefs' function types.
  4141.  
  4142. Tom Neff (tneff@panix.com)
  4143.     Edits (writes) the DESIGNxx.FAQ. Suggested BNF and wrote the
  4144.     intro to [A-1]. Created the WIF text standard. General advice.
  4145.  
  4146. Tom Nettleship (mastn@midge.bath.ac.uk)
  4147.     Explained BSP trees in comp.graphics.algorithms messages.
  4148.  
  4149. Elias Papavassilopoulos (ep104@cus.cam.ac.uk)
  4150.     Tons of technical info on EXE files in general and DOOM.EXE.
  4151.  
  4152. Robert D. Potter (potter@bronze.lcs.mit.edu)
  4153.     Theory about what BLOCKMAP is for and how the engine uses it.
  4154.  
  4155. Raphael Quinet (eedraq@chapelle.ericsson.se)
  4156.     Lots of rigorous contributions on linedef types and special 
  4157.     sectors. Not to mention DEU!
  4158.  
  4159. Colin Reed (dyl@cix.compulink.co.uk)
  4160.     I had the x upper and lower bounds for node bounding boxes 
  4161.     backwards a few versions ago.
  4162.  
  4163. Joost Schuur (jschuur@studserv.zdv.uni-tuebingen.de)
  4164.     Runs the doom-editing mailing list.
  4165.  
  4166. Steve Simpson (ssimpson@world.std.com)
  4167.     Corrected an error in the PNAMES section
  4168.  
  4169. S. Sproston (S.Sproston-SE2@cs.bham.ac.uk)
  4170.     Excellent work on linedef types.
  4171.  
  4172. Matt Tagliaferri (matt.tagliaferri@pcohio.com)
  4173.     Pointed out omission of TEXTURE1/2 pointer table in the 1.1
  4174.     specs. Also provided a good BLOCKMAP algorithm.
  4175.  
  4176. Ted Vessenes (tedv@geom.umn.ed)
  4177.     I had the THING angles wrong in the original specs.
  4178.  
  4179. You! Thanks for reading the "Unofficial" DOOM Specs!
  4180. +
  4181. UDS, Contents
  4182. =========================================
  4183. XXX/THIS SHOULD BE AT THE END OF THE FILE
  4184. =========================================
  4185.