home *** CD-ROM | disk | FTP | other *** search
/ 1,001 Nights of Doom / 1001NightsOfDoom1995wickedSensations.iso / text / doomhelp.zip / LINUXDM.HLP < prev    next >
Text File  |  1994-10-31  |  36KB  |  729 lines

  1.  
  2. [Note: This latest edition has been automatically formatted (with
  3. some minor hand editing) from the new! HTML version.  If you
  4. have a World Wide Web browser, open URL:
  5. http://jcomm.uoregon.edu/~stevev/Linux-DOOM-FAQ.html
  6. for the fancy hypertext version (including a few gratuitous
  7. screen shots).  If you don't, you'll notice this version looks
  8. somewhat different from the last version.]
  9.  
  10. Linux DOOM FAQ
  11.  
  12. (revision 4, 94/10/28 -- now in HTML!)
  13.  
  14. Compiled by Steve VanDevender (stevev@efn.org)
  15.  
  16.       1. Introduction
  17.           1) What's DOOM?
  18.           2) This document
  19.  
  20.       2. Where to get Linux DOOM and DOOM add-ons
  21.       3. Prerequisites and installation
  22.           1) Compatibility requirements
  23.           2) Installation instructions
  24.  
  25.       4. Problems and solutions
  26.           1) DISPLAY=(null)
  27.           2) ioctl(dsp, ...) == -1
  28.           3) Could not get shared memory
  29.           4) Error: Game mode indeterminate
  30.           5) R_TextureNumForName: SW1BLUE not found
  31.           6) Cannot find STBAR; Demo is from different version
  32.           7) Sounds are missing or garbled
  33.           8) Some (or all) keyboard commands don't work
  34.           9) Pixel doubling/tripling options look funny
  35.          10) DOOMWADDIR doesn't work as advertised
  36.          11) The colors are totally bogus
  37.          12) I have an 8-bit soundcard, how can I get sound?
  38.          13) Segmentation fault during startup
  39.          14) Other known problems (not all solvable)
  40.  
  41.       5. Configuration, tweaks and tricks
  42.           1) The .doomrc file
  43.           2) Linux-specific command-line switches
  44.           3) Making lower-resolution X video modes
  45.           4) Dealing with add-on WADs
  46.           5) DOOM editors
  47.  
  48.       6. Other sources of information
  49.  
  50. ------------------------------------------------------------------------------
  51.  
  52. 1. Introduction
  53.  
  54. 1.1) What's DOOM?
  55.  
  56. DOOM is a wildly popular action game developed by id Software where you, a
  57. trained space marine, have to fight your way through a series of increasingly
  58. hellish moonbases that have been invaded by demonic creatures.  It features
  59. stunning realtime texture-mapped 3-D graphics, chilling stereo sound effects,
  60. and frenetic gameplay.  You can also play DOOM in multi-player cooperative or
  61. Deathmatch games using modems, IPX networks, and TCP/IP networks.  id
  62. distributes a full-featured shareware version with the 9 levels of DOOM
  63. Episode 1, "Knee-deep in the Dead", and for a $40 registration fee you can buy
  64. two more episodes, "The Shores of Hell" and "Inferno".  A commercially
  65. distributed sequel, DOOM II: Hell on Earth, is being sold in stores.  DOOM
  66. enthusiasts have decoded the formats of DOOM resource files with the blessing
  67. and support of id's programmers and created literally hundreds of
  68. user-designed levels (often called WADs or PWADs) to supplement the 27 levels
  69. in the registered version of DOOM or the 32 levels in DOOM II (you must have
  70. the registered version of DOOM or DOOM II to use these add-on levels).
  71.  
  72. Although primarily marketed for MS-DOS, DOOM was originally developed on NeXT
  73. systems and has been or will be ported to SGI systems, Macintoshes, the Atari
  74. Jaguar, MS-Windows, and more.  Now, a Linux port done by David Taylor of id is
  75. available that runs with Linux and XFree86.
  76.  
  77. 1.2) This document
  78.  
  79. I have compiled this document from my own experiences and information other
  80. people have posted on the net.  Whenever I remembered to, I have credited
  81. sources of information.  If I missed crediting you, I'm sorry.
  82.  
  83. This document is meant to provide information to help you install and use the
  84. Linux port of DOOM.  It does not attempt to answer questions about Linux or
  85. DOOM that are better answered by other sources, like how to recompile your
  86. Linux kernel or how to play DOOM.  References to some of these other sources
  87. are included.
  88.  
  89. Please feel free to send comments, changes, and additions to me
  90. (stevev@efn.org).  If I use them, I will try to credit you.
  91.  
  92. Since things change rapidly, sometimes pieces of this document will be
  93. out-of-date or just plain wrong.
  94.  
  95. When I am looking for more information on a subject or have a parenthetical
  96. comment, I will enclose it [in brackets].
  97.  
  98. ------------------------------------------------------------------------------
  99.  
  100. 2. Where to get Linux DOOM and DOOM add-ons
  101.  
  102. David Taylor has uploaded his releases of Linux DOOM to sunsite.unc.edu,
  103. directory /pub/Linux/games/x11/action/doom , in file linxdoom.tgz .  This is a
  104. gzipped tar file of the executables and a README with documentation for the
  105. game.  doom1wad.tgz is the shareware DOOM data file doom1.wad.  This directory
  106. contains other Linux-specific DOOM support files, like the 16-to-8-bit sound
  107. converter doom_16to8bit_snd.2.tgz .  There are also a couple of joystick
  108. drivers, joystick4doom.tgz and smooth-joystick4doom.tgz .  I haven't tried
  109. other of these, so you'll have to figure out which one works better for you.
  110.  
  111. An HTML-formatted current index of the files in sunsite's Linux DOOM directory
  112. is available in
  113. ftp://sunsite.unc.edu/pub/Linux/games/x11/action/doom/INDEX.html .
  114.  
  115. infant2.sphs.indiana.edu is probably the biggest DOOM FTP site.  However,
  116. because of a space shortage, for the time being they have Linux DOOM have been
  117. moved to a different machine, mimosa.astro.indiana.edu, in directory
  118. pub/doom/id/LINUX [note: as of this writing, the linxdoom.tgz there does not
  119. have the DOOMWADDIR fix].  This is also one of the best sites for getting
  120. add-on WAD files and the Linux version of DEU, one of the most popular DOOM
  121. editors.  The WAD archives and other DOOM add-ons are still available there in
  122. pub/doom .
  123.  
  124. However, infant2 is frequently spammed to the limit with other DOOM fanatics,
  125. and you may want to go to a site that's topologically closer to you, so here
  126. are several sites that mirror infant2.  Here's a list of DOOM FTP sites
  127. recently posted to alt.games.doom.announce:
  128.  
  129.     o ftp.uwp.edu, pub/msdos/games/id/home-brew/doom/
  130.     o ftp.orst.edu, pub/gaming/doom/
  131.     o ftp.uni-erlangen.de, pub/pc/msdos/games/ID/DOOM-stuff/
  132.     o aurora.bld189.jccbi.gov, /infant2
  133.     o nctuccca.edu.tw, /PC/games/DOOM/
  134.     o ftp.cdrom.com, pub/doom/
  135.     o ftp.luth.se, pub/misc/games/doom/
  136.     o ftp.demon.co.uk, pub/ibmpc/games/id/
  137.     o ftp.sun.ac.za, pub/msdos/doom/
  138.     o ftp.sunet.se, pub/doom/
  139.  
  140. ftp.uwp.edu is id's official FTP site; their files are in directory
  141. pub/games/id.  The latest updates to MS-DOS DOOM appear there first (but
  142. probably propogate to infant2 and mirror sites quickly and could be more
  143. accessible there).
  144.  
  145. Jan Sandorf (jsf@krynn.solace.mg.se) has put Linux DOOM up for FTP in Europe
  146. at ftp.solace.mh.se, directory pub/Linux/games/, in file linux-doom.tar.gz .
  147.  
  148. If you want to buy the registered copy of DOOM for MS-DOS (which you would
  149. have to do to legally obtain the registered doom.wad file), call 1-800-IDGAMES
  150. [North America only; I'd like to know the number for international callers to
  151. use.] The cost is $40 plus (approximately) $6 shipping, charged to a major
  152. credit card.  Delivery time is usually around a couple of weeks.
  153.  
  154. ------------------------------------------------------------------------------
  155.  
  156. 3. Prerequisites and installation
  157.  
  158. This section describes what you'll need to have to run DOOM under Linux.
  159.  
  160. 3.1) Compatibility requirements
  161.  
  162. To run DOOM under Linux, you will need:
  163.  
  164.     o Linux 1.0 or above with SYSV IPC enabled
  165.     o XFree86 2.0 or above (if you compiled it from source yourself, make
  166.       sure to have the MITSHM extension enabled)
  167.     o The Linux DOOM executables
  168.     o A doom*.wad file for version 1.666 of DOOM (which contains all of
  169.       the game data)
  170.  
  171. For best performance, you should have a 486-33 or better with at least 8M of
  172. memory and a VLB or PCI-bus video card (although many people are getting good
  173. results with high-quality ISA-bus video cards as well).  There are quite a few
  174. variables that affect DOOM performance; some people find it unplayable on
  175. otherwise spiffy-looking systems and some 386-40 users think it's perfectly
  176. playable on their systems.
  177.  
  178. In addition, if you want sound effects, you will need:
  179.  
  180.     o The Linux sound driver (Voxware) 2.90 or above (cat /dev/sndstat to
  181.       find out your version)
  182.     o A 16-bit soundcard (such as the Sound Blaster 16, Pro Audio Spectrum
  183.       16, or Gravis Ultrasound).  You may be able to get your 8-bit
  184.       soundcard to work with the package doom_16to8bit_snd.tgz -- see the
  185.       section titled "I have an 8-bit soundcard, how can I get sound?".
  186.  
  187. Here's the output of ldd (which gives dynamic linking information for
  188. executables) for linuxxoom and sndserver.  If your shared libraries are older
  189. than these versions and you're having problems, you may want to consider
  190. upgrading them.
  191.  
  192. $ ldd linuxxdoom
  193.         libXt.so.3 (DLL Jump 3.1) => /usr/X386/lib/libXt.so.3.1.0
  194.         libX11.so.3 (DLL Jump 3.1) => /usr/X386/lib/libX11.so.3.1.0
  195.         libc.so.4 (DLL Jump 4.5pl26) => /lib/libc.so.4.5.26
  196. $ ldd sndserver
  197.         libm.so.4 (DLL Jump 4.5pl26) => /lib/libm.so.4.5.26
  198.         libc.so.4 (DLL Jump 4.5pl26) => /lib/libc.so.4.5.26
  199.  
  200. 3.2) Installation instructions
  201.  
  202. Obtain the file linxdoom.tgz from one of the FTP sites listed above.  If you
  203. don't have MS-DOS DOOM, you can get the shareware doom1.wad file, probably in
  204. the same place, in the file doom1wad.tgz.  If you have DOOM for MS-DOS, then
  205. you can use doom1.wad from the shareware version, doom.wad from the registered
  206. version, or doom2.wad from DOOM II.
  207.  
  208. The simplest installation is to extract linxdoom.tgz into a directory and
  209. place the doom*.wad file of your choice in that same directory.  You have to
  210. be running the X server before you can start DOOM.  If you have met all of the
  211. prerequisites above, then just run linuxxdoom and have a Hell of a good time!
  212.  
  213. If you don't have the appropriate sound card or sound driver available, rename
  214. or delete the program "sndserver" to disable sound effects.  Many respondents
  215. say that not running sndserver also speeds up the frame rate significantly.
  216.  
  217. If you would like to install the binaries in one directory and keep the
  218. doom*.wad file in another, you can set the DOOMWADDIR environment variable to
  219. the name of the directory where you are keeping doom*.wad so that linuxxdoom
  220. can findit.  You can also make a symbolic link to a copy of doom*.wad in a
  221. mounted MS-DOS filesystem if you don't want to duplicate doom*.wad into a
  222. Linux filesystem (although the game will start much faster if doom*.wad is in
  223. an ext2 filesystem).  If you can't get DOOMWADDIR to work, see the section
  224. titled "DOOMWADDIR doesn't work as advertised" below.
  225.  
  226. H. Peter Anvin  has written a shell script that acts as
  227. a front-end for Linux DOOM as part of a package including the DOOM executables
  228. and the sndcvt program for 8-bit sound support.  The package is available by
  229. anonymous FTP from eecs.nwu.edu in pub/linux/doom/doom.tgz .  The script
  230. installs into /usr/local/bin and runs DOOM from /usr/local/lib/doom.
  231.  
  232. Read the README.linux included in linxdoom.tgz.  It contains most of the
  233. information here (in briefer form), complete documentation of the game
  234. commands and gameplay features, and also explains id's policy towards the
  235. Linux port -- it exists because "Linux gives [David Taylor] a woody" and is
  236. not officially supported by id.  Linux DOOM does not support all MS-DOS doom
  237. features (notably music, mouse control, and modem or IPX network play) and
  238. probably never will add the missing ones.
  239.  
  240. For additional configuration options, see the section titled "Configuration,
  241. Tweaks, and Tricks".
  242.  
  243. ------------------------------------------------------------------------------
  244.  
  245. 4. Problems and solutions
  246.  
  247. Most of the headers in this section contain key words from an error message
  248. output by DOOM when something doesn't work.
  249.  
  250. 4.1) DISPLAY=(null)
  251.  
  252. This means you are trying to run DOOM without X. You need to start your X
  253. server before you can start DOOM.  If you try to set the environment variable
  254. DISPLAY without having an X server running, or the variable is set wrongly,
  255. then instead you'll probably get a message containing "Cannot connect to
  256. server".
  257.  
  258. If you have to install X, you will need to install the SVGA version of X or
  259. one of the versions tailored for various accelerated graphics chipsets, and
  260. run the display in 256-color mode (not monochrome or 16-color mode, or the 16-
  261. or 32-bit color modes available in XFree86 3.1).  DOOM will not work with a
  262. display whose color depth is anything other than 8 bits.
  263.  
  264. 4.2) ioctl(dsp, ...) == -1
  265.  
  266. These messages from the sndserver program indicate that you don't have the
  267. 2.90 version of the Linux soundcard driver installed (if you have a soundcard
  268. and the sound driver enabled at all).  The latest Linux DOOM release says you
  269. need the 3.0 drivers; I'm still running 2.90 and everything seems to be
  270. working OK.
  271.  
  272. The reason you need the more recent driver is that Hannu Savolainen (the sound
  273. driver author) included changes to the driver provided by David Taylor to
  274. support real-time sound effects.  Without the new driver, you will get delayed
  275. sounds, garbled sounds, or no sound at all.
  276.  
  277. You can get the latest Linux soundcard driver from sunsite.unc.edu, in the
  278. directory pub/Linux/kernel/sound, in file snd-driv-2.90.tar.gz.  Two patches,
  279. snd-driv-2.90.patch1.gz and snd-driv-2.90.patch2.gz , are also available
  280. there, so you should probably get them.  The snd-driv-2.90.tar.gz file is
  281. meant to replace the drivers/sound directory tree in the 1.0 Linux kernel
  282. source.  You will have to compile the kernel with the new, correctly
  283. configured sound driver, install the kernel, and boot from it before DOOM
  284. sound effects will work correctly.
  285.  
  286. If you get messages like "Could not find lumpname: [something]" then that
  287. means you don't have DOOM II yet.  These messages are harmless and occur
  288. normally; they just mean that sndserver can't find sound files specific to
  289. DOOM II.
  290.  
  291. 4.3) Could not get shared memory
  292.  
  293. Even if you have the current sound driver, you may need to recompile your
  294. kernel anyway to enable SYSV IPC, which includes shared memory (that is, the
  295. ability for multiple processes to share a common region of physical memory
  296. between them).  Linux DOOM uses a display buffer shared between the DOOM
  297. process and the X server to greatly speed up the process of drawing your DOOM
  298. display; without shared memory DOOM would have to transmit a 64K bitmap
  299. through a UNIX socket for every frame and would not perform well at all.
  300.  
  301. The question about whether to include SYSV IPC is in the first round of
  302. questions asked when you run "make config" in the Linux kernel source
  303. directory.
  304.  
  305. 4.4) Error: Game mode indeterminate
  306.  
  307. DOOM is looking for the doom*.wad file that it needs.  This could mean that
  308. you haven't installed a doom*.wad file or that you have an incorrect setting
  309. for the DOOMWADDIR environment variable that DOOM uses to locate doom*.wad.
  310.  
  311. The name of the WAD file is significant and is used to determine what mode the
  312. game should run in, like this:
  313.  
  314.     o doom1.wad
  315.       Run in shareware mode (no -file switch, only the first episode is
  316.       available)
  317.     o doom.wad
  318.       Run in registered mode (-file switch works, three episodes
  319.       available)
  320.     o doom2.wad
  321.       Run in DOOM II mode (-file switch works, one episode of 32 levels)
  322.  
  323. 4.5) R_TextureNumForName: SW1BLUE not found
  324.  
  325. You did something dumb and gave the WAD file the wrong name.  DOOM determines
  326. whether it should act like the shareware or registered version by the name of
  327. the WAD file.  The shareware wad (about 4.8 megs in size) is called doom1.wad,
  328. and the registered version (about 11 megs) is called doom.wad.  If you rename
  329. the shareware doom1.wad to doom.wad, DOOM will die when it can't find
  330. resources for the registered version in the shareware WAD.  If you rename the
  331. registered doom.wad to doom1.wad, then DOOM won't let you play the second or
  332. third episodes.
  333.  
  334. 4.6) Cannot find STBAR; Demo is from different version
  335.  
  336. These messages come up if your doom*.wad file is from a version of DOOM other
  337. than the latest one, 1.666.  You will need to patch your doom*.wad file to the
  338. latest version.  Unfortunately, you will have to install DOOM under MS-DOS and
  339. run DOS to do this, since the patch program runs under MS-DOS.  If you can't
  340. bring yourself to do this, get doom1wad.tgz with the shareware version of the
  341. 1.666 doom1.wad, or buy the MS-DOS registered DOOM and get a friend with DOS
  342. to patch it to 1.666 and give you the files.
  343.  
  344. If you are really desperate, try invoking doom with the "-warp" command-line
  345. option to jump directly into the game and skip the demos:
  346.  
  347. linuxxdoom -warp 1 1
  348.  
  349. 4.7) Sounds are missing or garbled
  350.  
  351. This could happen along with the message described in the section titled
  352. "ioctl(dsp,...)==-1" above.  If sounds are missing, but you have all the other
  353. prerequisites taken care of, make sure that sndserver is in your executable
  354. search path where DOOM can find it.
  355.  
  356. 4.8) Some (or all) keyboard commands don't work
  357.  
  358. If none of the advertised keyboard commands work, put the mouse pointer inside
  359. the DOOM window (or click on it if your window manager is set for
  360. click-to-type input focusing) so that it is the keyboard focus.
  361.  
  362. If just the SHIFT, CTRL, or ALT keys don't seem to work right in DOOM, this is
  363. the result of your X window manager wanting to grab certain keys for its
  364. functions.  fvwm and olwm/olvwm have default actions or modifiers bound to the
  365. SHIFT, ALT, and CTRL keys.  You can redefine DOOM's key command bindings (see
  366. the section titled "The .doomrc File"), turn off the window manager bindings
  367. for those keys (see your window manager man page), or use a different window
  368. manager (twm is commonly available and doesn't treat those keys specially).
  369.  
  370. 4.9) Pixel doubling/tripling options look funny
  371.  
  372. The very first released version of Linux DOOM had a bug with the -2, -3, and
  373. -4 command-line switches that scale the DOOM window size.  David Taylor says
  374. you're stupid to use them (they kill the frame rate) but ended up putting an
  375. updated linxdoom.tgz on sunsite a couple days after the first version was
  376. released that fixed the problem with -2 and -3.  Pixel quadrupling (the -4
  377. switch) is still broken, but you need a display bigger than 1280x1024 to use
  378. that anyway.  You really are best off not using -2, -3, or -4 to magnify the
  379. window.  You can use a lower-resolution video mode in X (section 5.3) to
  380. magnify the window and get maximum frame rate.
  381.  
  382. 4.10) DOOMWADDIR doesn't work as advertised
  383.  
  384. The originally released version of Linux DOOM had another bug -- the
  385. DOOMWADDIR environment variable couldn't be used to locate the doom*.wad file
  386. in a directory other than the current one.  This has been fixed in the most
  387. recent release (94/9/13).
  388.  
  389. 4.11) The colors are totally bogus
  390.  
  391. DOOM uses a local colormap in X because it needs all 256 colors.  Your mouse
  392. pointer must be inside the DOOM window for the DOOM colors to look right.  Of
  393. course, this makes the colors of the rest of your display look weird instead.
  394. DOOM also does palette tricks that may cause your entire screen to flash red,
  395. white, or green as it manipulates the colormap.
  396.  
  397. 4.12) I have an 8-bit soundcard, how can I get sound?
  398.  
  399. Harry C Pulley (hpulley@uoguelph.ca) writes:
  400.  
  401.      8 bit sound for DOOM:
  402.  
  403.      Charles  wrote a package called
  404.      doom_16to8bit_snd.tgz on sunsite.unc.edu in
  405.      /pub/Linux/Incoming.  It probably won't stay in that
  406.      directory and is probably available from other sites as
  407.      well.  This package allows users of non-SB16 cards to hear
  408.      the sound effects on their card.  It works by patching
  409.      sndserver to send the output to a pipe which sndcvt reads
  410.      and sends, in 8-bit format, to /dev/dsp.  Most cards which
  411.      have a 8-bit /dev/dsp device should work with this setup.
  412.  
  413.      Paraphrasing the readme file, you must run "sed
  414.      s,/dev/dsp,/tmp/dsp,g  sndserver.new"; then
  415.      replace sndserver with sndserver.new.  Next, run "mknod
  416.      /tmp/dsp p" to create a pipe for sndcvt.
  417.  
  418.      Now, to run doom with sound, run "sndcvt & linuxxdoom"
  419.      (optionally add a "&" to put the linuxxdoom in the
  420.      background).  sndcvt will automatically die when doom is
  421.      finished.
  422.  
  423.      The package includes a binary and source code.
  424.  
  425.      On my 486DX-33 with 8MB of RAM, VLB video and a clone 8-bit
  426.      SB card, this works great and I get good performance.  The
  427.      sound is slightly behind the action but I have heard users
  428.      with genuine SB16 cards complain about the same thing.  I
  429.      have never heard it on a SB16 so I can't tell you if there
  430.      is more delay or not.  I suspect that there might be more
  431.      delay due to pipe and context switch overhead.
  432.  
  433.      Note that you still only get sound effects; no background
  434.      music :-(
  435.  
  436. 4.13) Segmentation fault during startup
  437.  
  438. David.Lecomber@comlab.oxford.ac.uk had this problem and said that upgrading
  439. his system's C and X11 shared libraries to the current versions got rid of it.
  440. See the section entitled "Compatibility Requirements" for full compatibility
  441. information.
  442.  
  443. 4.14) Other known problems (not all solvable)
  444.  
  445. The 1.666 registered doom.wad has a bug in E3M9 (Warrens) resulting from a
  446. bogus linedef in the level.  A binary patch for this has been discussed in
  447. alt.games.doom and if you know what I'm talking about here, then you can
  448. probably manage to apply it and may even want to.
  449.  
  450. Sound PWADs (WAD files that are intended to replace DOOM sound effects) don't
  451. seem to work with Linux DOOM.
  452.  
  453. You can't use the mouse for a control device.  Well, you can (see the section
  454. titled "Linux-specific command-line switches" ) but it doesn't work very well.
  455. This is one of the most frustrating things for me (I'm a die-hard mouse user
  456. because I find it the best all-around control for both speed and precision)
  457. but I can think of several programming reasons why it is very difficult to
  458. support under X.
  459.  
  460. David Taylor contributes this explanation about the lack of mouse support and
  461. music in Linux DOOM:
  462.  
  463.      Mouse:
  464.  
  465.      I'm going to go into this one because it's pretty frustrating, and
  466.      it would be nice if a sympathetic X coder took it to heart.  You
  467.      mentioned the grim -grabmouse thing.  That was one of several failed
  468.      attempts.  First off, the mouse cursor is pretty darn important in
  469.      X and other windowed environments.  If a process is misbehaving,
  470.      you drag the pointer elsewhere and kill it.  It's therefore considered
  471.      exteremely rude (and rightly so) to grab all the mouse input.
  472.  
  473.      Nonetheless, if you think about how mouse control works for DOOM,
  474.      this is what is required.  So assuming we're going to be rude, what
  475.      I need next is a way to get what are called "mickeys", the bare-bones
  476.      information sent from the mouse to the computer.  They're basically
  477.      a delta-x and delta-y movement pair that simply tell you how much
  478.      the mouse has moved.
  479.  
  480.      Unfortunately, X in its attempt to be nice to most normal apps,
  481.      does not give you this information.  Instead, it gives you the new
  482.      pointer position on the X server.  This causes several problems.
  483.      One is that it doesn't have to stream this information to you at
  484.      the rate the mouse is providing it.  It can simply collect up
  485.      several delta pairs and give you the resulting new position.  That
  486.      causes jerkiness.  But let's say for the sake of argument (and the
  487.      sake of -grabmouse) you sort of reverse this by taking the deltas
  488.      of what X is feeding you.
  489.  
  490.      What happens when you move the mouse to the left side of the window
  491.      and want to move your character left?  Nothing.  It registers as
  492.      zero movement even though you're moving your mouse.  You therefore
  493.      need to periodically warp the mouse pointer back to the center of
  494.      the window to keep it from getting near the edge.
  495.  
  496.      I think this is where the real trouble is coming from.  I believe
  497.      information is being lost in the warp.  A smooth drag to the left
  498.      has to be interrupted several times a second to keep it from getting
  499.      to the edge.  These interruptions appear as stutters in your
  500.      movement, and you get that not-too-nifty feel of -grabmouse.
  501.  
  502.      The thought of opening up ol' /dev/mouse even though the X server
  503.      is using it crossed my mind, but I didn't even try.  I wasn't
  504.      looking for trouble.
  505.  
  506.      But besides it being somewhat painful to implement, the thought
  507.      that everyone would have to play with the keyboard in deathmatches
  508.      appealed to be instantly.  I'm a fairly good keyboard player but
  509.      feel like a blind cripple against any decent mouse player.  I
  510.      know, I know.. power corrupts.. :)
  511.  
  512.      I should point out here that Hannu is not the only nice guy writing
  513.      code for Linux.  The author of svgalib, Harm Hanemaaijer, was trying
  514.      to sway me to write an svgalib version.  I said I didn't have time
  515.      and wanted to write one version for all high-end UNIX platforms
  516.      and that by the way, svgalib had no provision for portable mouse
  517.      measurements.  He promptly added that feature, and I hope other
  518.      games out there capitalize on it as I probably should have.  I am
  519.      the part owner of a small shareware game company on the side, and
  520.      if it's any comfort to him, they're writing an extremely high-quality
  521.      game which will be available for Linux with both X and svgalib
  522.      versions.  (sorry- no dates/details.  deadlines=stress.)
  523.  
  524.      Music:
  525.  
  526.      Because the existing code isn't ours and isn't terribly portable
  527.      in this case, it's a pain to do from scratch, and although missed,
  528.      it is not essential to the experience.  Bobby's gonna kill me for
  529.      saying that.
  530.  
  531. ------------------------------------------------------------------------------
  532.  
  533. 5. Configuration, tweaks, and tricks
  534.  
  535. 5.1) The .doomrc file
  536.  
  537. Your .doomrc file has a variety of customization options for DOOM.  The MS-DOS
  538. version calls the file default.cfg instead and has a SETUP utility that can
  539. change many of the important options.  Since you're a wizardly Linux user, you
  540. get to edit the file manually instead.  Some options are set within DOOM
  541. itself, and those won't be described here.
  542.  
  543. The file has a simple format: The first word on each line is a DOOM variable,
  544. and following it after some whitespace characters is that variable's value.
  545. If you don't have a .doomrc in your home directory when you first start DOOM,
  546. it will create one with default values.  Once you customize it, DOOM will keep
  547. those values.
  548.  
  549. A group of variables contains keycodes for DOOM keyboard commands.  These are:
  550.  
  551. key_right: turns you to the right key_left: turns you to the left key_up:
  552. moves you forward key_down: moves you backward key_strafeleft: moves you
  553. sideways to the left key_straferight: moves you sideways to the right
  554. key_fire: shoots or activates your current weapon key_use: activates doors,
  555. lifts, and switches key_strafe: when held down, key_right and key_left act
  556. like key_straferight and key_strafeleft key_speed: when held down, increases
  557. the rate of motion of all movement keys The number following each is a keycode
  558. for the desired key.  For most normal typing keys, this is the ASCII code of
  559. the character generated by the unshifted key, i.e.  the 'A' key has keycode 97
  560. (ASCII lowercase 'a').  I haven't figured out what the keycodes are for all of
  561. the non-typing keys, but those given in the default .doomrc are:
  562.  
  563. up-arrow 173 down-arrow 175 left-arrow 172 right-arrow 174 SHIFT 182 CTRL 157
  564. ALT 184 Note that your X window manager may interfere with the use of SHIFT,
  565. CTRL, or ALT (see section 4.7).  DOOM also has some non-configurable commands
  566. -- ESC to bring up the main menu, 1-7 to change weapons, F1-F10 for various
  567. options, TAB to toggle the automap.  You probably don't want to assign other
  568. commands to those keys, and you may also see your window manager override the
  569. function keys.
  570.  
  571. mb_used is a Linux-specific variable in .doomrc.  It controls the size of the
  572. heap used by DOOM for dynamic storage.  The approximate memory requirements of
  573. your DOOM process are 1.6+mb_used megabytes for DOOM itself, and another 1.6
  574. megabytes or so for sndserver.  mb_used is 2 by default.  If you have more
  575. memory, you may slightly reduce hesitations in the game caused by DOOM
  576. swapping resources in and out by setting it to a higher value (as long as this
  577. doesn't induce virtual-memory swapping in Linux itself); increasing it really
  578. has no consistent beneficial effect on overall frame rate in timing
  579. experiments that I've done, but I run with mb_used set to 4 anyway.
  580.  
  581. sndserver contains the pathname of the sndserver program, normally just
  582. "sndserver".
  583.  
  584. snd_channels controls the number of simultaneous sound effects that DOOM will
  585. try to play.  By default, it will play no more than 3 overlapping sound
  586. effects at once.  If you have a really nifty sound card that can handle it and
  587. don't mind a slight performance hit, you can set this to a higher value (I
  588. successfully use 8 with my Gravis Ultrasound).
  589.  
  590. If I haven't mentioned a .doomrc variable here, it's either because 1) you can
  591. control it from DOOM itself, 2) it's documented in the standard DOOM README,
  592. or 3) it's completely irrelevant in Linux DOOM.
  593.  
  594. 5.2) Linux-specific command-line switches
  595.  
  596. These command-line switches are (usually) specific to the Linux version (and
  597. maybe other UNIX/X versions).
  598.  
  599. -disp and -geom appear to be analogous to the standard X -display and
  600. -geometry command line options for specifying the X server to connect to and
  601. the initial window geometry.  -geom doesn't take the standard X geometry
  602. specification (WxH+X+Y) but instead takes two numeric arguments for the
  603. initial X and Y position of the window (which may be ignored by your window
  604. manager).
  605.  
  606. -2, -3, and -4 respectively double, triple, and quadruple the window size and
  607. pixel size of the DOOM window.  -4 doesn't currently work right (and probably
  608. never will).  -2 and -3 work but slow down your frame rate immensely.
  609.  
  610. -grabmouse is an undocumented switch that enables what is apparently an
  611. experimental mouse control mode for X. You probably won't like it at all, so
  612. be warned before you try it.  The frame rate goes way, way down when you use
  613. it, but other than that mouse controls seem to work like they do in DOS.  You
  614. may also have trouble if you use click-to-type keyboard focusing in your
  615. window manager, since you don't have any time to click on the window to set
  616. the keyboard focus before DOOM grabs your mouse.
  617.  
  618. The -net switch that controls network game play has a different syntax.  You
  619. follow it first with the node number your machine should use, and then list
  620. the domain names or IP addresses of the other machines in the net game.
  621.  
  622. Command-line switches not described here (there are lots) are covered in the
  623. standard DOOM documentation, which is in the README.linux file that comes with
  624. the Linux executables.
  625.  
  626. 5.3) Making lower-resolution X video modes
  627.  
  628. Because the -2 and -3 switches make your DOOM window readable at the expense
  629. of the game's frame rate, you will probably want to use a low-resolution video
  630. mode in XFree86 as a way of expanding the window to a readable size while
  631. keeping the game fast.
  632.  
  633. Unfortunately, many of the video mode definitions being thrown around the net
  634. are absolutely ludicrous.  They may work for their authors, but some have
  635. refresh rates so high that those authors may soon be found dead with charred
  636. bits of exploded monitor blasted into their steaming bodies.
  637.  
  638. If you want to avoid a toasted monitor and possible flaming horrible death,
  639. the safest thing to do is probably to just use a standard mode like 640x480
  640. that monitors are designed to handle.  If you try for a lower-resolution mode
  641. than that, make sure that you don't exceed your monitor's horizontal or
  642. vertical refresh rates.  Use as low of an SVGA dot clock as your card will
  643. support and be aware that 320x200 VGA uses some option bits in the VGA
  644. registers that double pixels horizontally and vertically -- you probably can't
  645. get a SVGA card to duplicate that mode without using those mode bits.
  646.  
  647. XFree86 3.1 has a generic 320x200 256-color VGA mode driver (use chipset
  648. "generic").  You might try that.
  649.  
  650. 5.4) Dealing with add-on WADs
  651.  
  652. Linux DOOM is perfectly happy with the supplementary WAD files that MS-DOS
  653. DOOMers have been playing for months, with the important exception that sound
  654. WADs don't seem to work at all (you can specify them, but no sound effects get
  655. replaced).  IMPORTANT: You must have the registered version of DOOM (with the
  656. 11 meg doom.wad) or DOOM II (with a 15 meg doom2.wad) to use the -file
  657. command-line option that loads add-on WADs.  Buy a copy of DOOM and join the
  658. fun.
  659.  
  660. One problem you may encounter is that older WAD files containing their own
  661. demos may cause DOOM to abort with the message "Error: Demo is from a
  662. different game version!".  This happens for MS-DOS-based DOOM players as well,
  663. and is because DOOM won't play demos from a different game version.  It
  664. probably doesn't mean that you can't play the WAD; it just means that you will
  665. have to use command-line options to start the level you want without going
  666. through the WAD's demos.  For example, to start cleim10.wad, which replaces
  667. all of episode 2, say something like:
  668.  
  669. linuxxdoom -file cleim10.wad -skill 4 -warp 2 1
  670.  
  671. This loads the replacement wad cleim10.wad, sets your difficulty level to
  672. ultra-violence, and "warps" to episode 2, level 1.
  673.  
  674. 5.5) DOOM editors
  675.  
  676. Your friends cursed with MS-DOS can run all kinds of DOOM map editors that let
  677. them modify levels or create their own, change the "thing tables" in DOOM.EXE,
  678. and otherwise have all kinds of fun.  So far, few of these exist for Linux.  I
  679. have heard of a port of the popular DEU editor that runs with svgalib under
  680. Linux, and rumors are that a later version will run under X. I would be
  681. interested in in hearing from authors of DOOM utilities who would be willing
  682. to release source code for porting them to Linux.  Please contact me
  683. (stevev@efn.org) if you would like to let me try porting your utility to
  684. Linux.
  685.  
  686. ------------------------------------------------------------------------------
  687.  
  688. 6. Other sources of information
  689.  
  690. You may have received this document as a news posting formatted from my HTML
  691. source.  If you would like to see this as a World Wide Web page, open the URL
  692. http://jcomm.uoregon.edu/~stevev/Linux-DOOM-FAQ.html.
  693.  
  694. I said this at least three times already, but read the file README.linux that
  695. comes with the binaries.  It's a note from David Taylor stuck on the top of
  696. the MS-DOS README file, so it's got what you need to know about the game and
  697. how to play it.
  698.  
  699. If you need to know how to recompile your Linux kernel, configure XFree86, or
  700. edit your own WADs, there are much better FAQs available than I can write.
  701.  
  702. For Linux and XFree86 configuration information, there are FAQs available by
  703. FTP and WWW from sunsite.unc.edu.  Start with the file
  704. pub/Linux/docs/HOWTO/META-FAQ or the Linux Documentation Project Home Page at
  705. URL http://sunsite.unc.edu/mdw/linux.html.
  706.  
  707. DOOM also has a large and detailed FAQ available from infant2.sphs.indiana.edu
  708. in directory pub/doom/text/ , file dmfaq58.txt .  Much of the information is
  709. tailored to MS-DOS specific problems with DOOM, but is probably the best
  710. general introduction to the game and its culture.
  711.  
  712. A DOOM WWW (World Wide Web) page, DoomGate , is available at URL
  713. http://www.cedar.buffalo.edu/~kapis-p/doom/DoomGate.html.
  714.  
  715. "finger help@idsoftware.com" returns a status report about DOOM and Id's next
  716. game, Quake.
  717.  
  718. The comp.os.linux.help newsgroup is a good place to ask for information about
  719. how to set up Linux itself.  The comp.windows.x.i386unix newsgroup deals
  720. mostly with XFree86 for various 386/486 UNIX variants including Linux.
  721. alt.games.doom is where the DOOMers hang out (beware -- they're mostly MS-DOS
  722. users).  It's also where copies of the DOOM FAQ are posted.
  723. alt.games.doom.announce is where many people post announcements of DOOM-based
  724. utilities and new WAD files.
  725.  
  726.  
  727.  
  728.  
  729.