From 58398fe06fa31c18e24d0ddb2c4b7badf911edfb Mon Sep 17 00:00:00 2001 From: Randy Heit <> Date: Wed, 15 Aug 2001 00:00:00 +0000 Subject: [PATCH] ZDoom 1.23b25. --- Makefile | 172 ++ code/c_dispatch.h | 98 - code/decallib.cpp | 403 --- code/v_text.h | 38 - code/win32/i_music.cpp | 1062 -------- code/win32/mus2strm.h | 45 - {code/docs => docs}/BUILDLIC.TXT | 0 {code/docs => docs}/README.Carmack | 0 {code/docs => docs}/README.asm | 0 {code/docs => docs}/README.gl | 0 {code/docs => docs}/classes.txt | 5 - docs/colors.txt | 756 ++++++ docs/commands.txt | 1742 +++++++++++++ code/docs/DOOMLIC.TXT => docs/doomlic.txt | 0 docs/history.txt | 534 ++++ {code/docs => docs}/notes.txt | 0 code/docs/Rh-log.txt => docs/rh-log.txt | 310 +++ docs/zdoom.txt | 1134 +++++++++ install | 35 + {code => src}/actor.h | 9 +- {code => src}/am_map.cpp | 26 +- {code => src}/am_map.h | 0 {code => src}/autosegs.h | 0 {code => src}/autostart.cpp | 0 {code => src}/autozend.cpp | 0 {code => src}/b_bot.cpp | 4 +- {code => src}/b_bot.h | 0 {code => src}/b_func.cpp | 10 +- {code => src}/b_game.cpp | 18 +- {code => src}/b_move.cpp | 0 {code => src}/b_think.cpp | 10 +- {code => src}/basicinlines.h | 0 {code => src}/blocks.nas | 0 {code => src}/c_bind.cpp | 251 +- {code => src}/c_bind.h | 4 +- {code => src}/c_cmds.cpp | 83 +- {code => src}/c_console.cpp | 663 ++--- {code => src}/c_console.h | 4 +- {code => src}/c_cvars.cpp | 83 +- {code => src}/c_cvars.h | 34 +- {code => src}/c_dispatch.cpp | 512 ++-- src/c_dispatch.h | 117 + {code => src}/cmdlib.cpp | 0 {code => src}/cmdlib.h | 0 {code => src}/colormatcher.cpp | 20 +- {code => src}/colormatcher.h | 8 +- {code => src}/configfile.cpp | 0 {code => src}/configfile.h | 2 +- {code => src}/ct_chat.cpp | 113 +- {code => src}/d_dehacked.cpp | 169 +- {code => src}/d_dehacked.h | 2 +- {code => src}/d_event.h | 0 {code => src}/d_gui.h | 34 +- {code => src}/d_items.cpp | 2 +- {code => src}/d_items.h | 2 +- {code => src}/d_main.cpp | 49 +- {code => src}/d_main.h | 0 {code => src}/d_net.cpp | 12 +- {code => src}/d_net.h | 0 {code => src}/d_netinf.h | 2 +- {code => src}/d_netinfo.cpp | 20 +- {code => src}/d_player.h | 1 - {code => src}/d_protocol.cpp | 2 +- {code => src}/d_protocol.h | 2 +- {code => src}/d_textur.h | 0 {code => src}/d_ticcmd.h | 0 src/decallib.cpp | 587 +++++ {code => src}/decallib.h | 51 +- {code => src}/dobject.cpp | 4 +- {code => src}/dobject.h | 0 {code => src}/doomdata.h | 0 {code => src}/doomdef.cpp | 0 {code => src}/doomdef.h | 17 +- {code => src}/doomstat.cpp | 2 +- {code => src}/doomstat.h | 12 +- {code => src}/doomtype.h | 31 +- {code => src}/dsectoreffect.cpp | 0 {code => src}/dsectoreffect.h | 2 +- {code => src}/dthinker.cpp | 4 +- {code => src}/dthinker.h | 2 +- {code => src}/errors.h | 2 +- {code => src}/f_finale.cpp | 2 +- {code => src}/f_finale.h | 0 {code => src}/f_wipe.cpp | 2 +- {code => src}/f_wipe.h | 0 {code => src}/farchive.cpp | 153 +- {code => src}/farchive.h | 22 +- src/fmodsound/i_music.cpp | 1912 ++++++++++++++ .../I_music.h => src/fmodsound/i_music.h | 2 +- {code/win32 => src/fmodsound}/i_sound.cpp | 110 +- {code/win32 => src/fmodsound}/i_sound.h | 4 + {code => src}/g_doom/a_arachnotron.cpp | 0 {code => src}/g_doom/a_archvile.cpp | 0 {code => src}/g_doom/a_bossbrain.cpp | 4 +- {code => src}/g_doom/a_bruiser.cpp | 0 {code => src}/g_doom/a_cacodemon.cpp | 0 {code => src}/g_doom/a_cyberdemon.cpp | 0 {code => src}/g_doom/a_demon.cpp | 0 {code => src}/g_doom/a_doomarmor.cpp | 0 {code => src}/g_doom/a_doomartifacts.cpp | 4 +- {code => src}/g_doom/a_doomdecorations.cpp | 0 {code => src}/g_doom/a_doomglobal.h | 2 +- {code => src}/g_doom/a_doomhealth.cpp | 0 {code => src}/g_doom/a_doomimp.cpp | 0 {code => src}/g_doom/a_doomkeys.cpp | 0 {code => src}/g_doom/a_doommisc.cpp | 9 +- {code => src}/g_doom/a_doomplayer.cpp | 1 + {code => src}/g_doom/a_doomweaps.cpp | 89 +- {code => src}/g_doom/a_fatso.cpp | 0 {code => src}/g_doom/a_keen.cpp | 0 {code => src}/g_doom/a_lostsoul.cpp | 8 +- {code => src}/g_doom/a_painelemental.cpp | 2 +- {code => src}/g_doom/a_possessed.cpp | 0 {code => src}/g_doom/a_revenant.cpp | 0 {code => src}/g_doom/a_spidermaster.cpp | 0 {code => src}/g_doom/doom_sbar.cpp | 9 +- {code => src}/g_game.cpp | 151 +- {code => src}/g_game.h | 0 {code => src}/g_heretic/a_beast.cpp | 0 {code => src}/g_heretic/a_chicken.cpp | 0 {code => src}/g_heretic/a_clink.cpp | 0 {code => src}/g_heretic/a_dsparil.cpp | 0 {code => src}/g_heretic/a_hereticambience.cpp | 0 {code => src}/g_heretic/a_hereticarmor.cpp | 0 .../g_heretic/a_hereticartifacts.cpp | 0 .../g_heretic/a_hereticdecorations.cpp | 0 {code => src}/g_heretic/a_hereticglobal.h | 2 +- {code => src}/g_heretic/a_hereticimp.cpp | 0 {code => src}/g_heretic/a_heretickeys.cpp | 0 {code => src}/g_heretic/a_hereticmisc.cpp | 2 +- {code => src}/g_heretic/a_hereticplayer.cpp | 3 +- {code => src}/g_heretic/a_hereticweaps.cpp | 114 +- {code => src}/g_heretic/a_ironlich.cpp | 0 {code => src}/g_heretic/a_knight.cpp | 0 {code => src}/g_heretic/a_mummy.cpp | 0 {code => src}/g_heretic/a_snake.cpp | 0 {code => src}/g_heretic/a_wizard.cpp | 0 {code => src}/g_heretic/heretic_sbar.cpp | 6 +- {code => src}/g_hexen/__hexentemp.cpp | 0 {code => src}/g_hexen/a_bishop.cpp | 0 {code => src}/g_hexen/a_debris_and_spike.cpp | 0 {code => src}/g_hexen/a_ettin.cpp | 0 {code => src}/g_hexen/a_hexendecorations.cpp | 0 {code => src}/g_hexen/a_hexenfighter.cpp | 4 +- {code => src}/g_hexen/a_hexenglobal.h | 2 +- {code => src}/g_hexen/a_hexenspecialdecs.cpp | 5 +- {code => src}/g_level.cpp | 135 +- {code => src}/g_level.h | 18 +- {code => src}/g_raven/a_artiegg.cpp | 0 {code => src}/g_raven/a_artitele.cpp | 2 +- {code => src}/g_raven/a_minotaur.cpp | 0 {code => src}/g_raven/a_ravenambient.cpp | 8 +- {code => src}/g_raven/a_ravenartifacts.cpp | 0 {code => src}/g_raven/a_ravenhealth.cpp | 0 {code => src}/g_raven/ravenshared.h | 2 +- {code => src}/g_shared/a_action.cpp | 0 {code => src}/g_shared/a_action.h | 0 {code => src}/g_shared/a_artifacts.cpp | 10 +- {code => src}/g_shared/a_artifacts.h | 2 +- {code => src}/g_shared/a_bridge.cpp | 4 +- {code => src}/g_shared/a_camera.cpp | 0 {code => src}/g_shared/a_decals.cpp | 73 +- {code => src}/g_shared/a_fountain.cpp | 0 src/g_shared/a_lightning.cpp | 200 ++ src/g_shared/a_lightning.h | 32 + {code => src}/g_shared/a_movingcamera.cpp | 0 {code => src}/g_shared/a_pickups.cpp | 49 +- {code => src}/g_shared/a_pickups.h | 6 +- {code => src}/g_shared/a_quake.cpp | 2 +- {code => src}/g_shared/a_secrettrigger.cpp | 0 {code => src}/g_shared/a_sectoraction.cpp | 0 {code => src}/g_shared/a_sharedglobal.h | 7 +- {code => src}/g_shared/a_sharedmisc.cpp | 0 {code => src}/g_shared/a_skies.cpp | 0 {code => src}/g_shared/a_splashes.cpp | 0 {code => src}/g_shared/a_waterzone.cpp | 0 {code => src}/g_shared/a_weapons.cpp | 147 +- {code => src}/g_shared/hudmessages.cpp | 4 +- {code => src}/g_shared/sbar.h | 4 +- {code => src}/g_shared/shared_sbar.cpp | 82 +- {code => src}/gameconfigfile.cpp | 43 +- {code => src}/gameconfigfile.h | 2 +- {code => src}/gccinlines.h | 52 +- {code => src}/gi.cpp | 8 +- {code => src}/gi.h | 4 +- {code => src}/gstrings.h | 2 +- {code => src}/hu_stuff.h | 0 {code/win32 => src}/i_cd.h | 2 +- {code/win32 => src}/i_video.h | 0 {code => src}/info.cpp | 15 +- {code => src}/info.h | 4 +- {code => src}/infodefaults.cpp | 13 +- {code => src}/infomacros.h | 10 +- src/linux/Makefile | 424 ++++ src/linux/dikeys.h | 155 ++ src/linux/expandorama.h | 50 + src/linux/expandorama.nas | 596 +++++ src/linux/files.mak | 99 + src/linux/hardware.cpp | 201 ++ {code/win32 => src/linux}/hardware.h | 0 src/linux/hw_svgalib.cpp | 1027 ++++++++ src/linux/hw_x.cpp | 2212 +++++++++++++++++ src/linux/i_cd.cpp | 154 ++ src/linux/i_input.cpp | 312 +++ src/linux/i_input.h | 8 + src/linux/i_main.cpp | 143 ++ src/linux/i_music.cpp | 327 +++ src/linux/i_music.h | 31 + src/linux/i_net.cpp | 805 ++++++ {code/win32 => src/linux}/i_net.h | 0 src/linux/i_sound.cpp | 724 ++++++ src/linux/i_system.cpp | 428 ++++ src/linux/i_system.h | 157 ++ src/linux/i_video.h | 69 + src/linux/nullvideo.cpp | 172 ++ src/linux/nullvideo.h | 22 + src/linux/sdlvideo.cpp | 336 +++ src/linux/sdlvideo.h | 24 + {code => src}/lists.h | 2 +- {code => src}/lumpconfigfile.cpp | 0 {code => src}/lumpconfigfile.h | 2 +- {code => src}/m_alloc.cpp | 8 +- {code => src}/m_alloc.h | 2 +- {code => src}/m_argv.cpp | 0 {code => src}/m_argv.h | 2 +- {code => src}/m_bbox.cpp | 0 {code => src}/m_bbox.h | 2 +- {code => src}/m_cheat.cpp | 11 - {code => src}/m_cheat.h | 0 src/m_crc32.h | 14 + {code => src}/m_fixed.cpp | 0 {code => src}/m_fixed.h | 2 +- {code => src}/m_menu.cpp | 252 +- {code => src}/m_menu.h | 4 +- {code => src}/m_misc.cpp | 152 +- {code => src}/m_misc.h | 2 - {code => src}/m_options.cpp | 33 +- {code => src}/m_random.cpp | 0 {code => src}/m_random.h | 3 + {code => src}/m_swap.h | 0 {code => src}/misc.nas | 184 +- {code => src}/mscinlines.h | 0 src/mus2midi.cpp | 231 ++ src/mus2midi.h | 45 + {code => src}/p_acs.cpp | 19 +- {code => src}/p_acs.h | 5 +- {code => src}/p_ceiling.cpp | 11 +- {code => src}/p_doors.cpp | 0 {code => src}/p_effect.cpp | 4 +- {code => src}/p_effect.h | 2 +- {code => src}/p_enemy.cpp | 48 +- {code => src}/p_enemy.h | 2 +- {code => src}/p_floor.cpp | 0 {code => src}/p_inter.h | 1 - {code => src}/p_interaction.cpp | 43 +- {code => src}/p_lights.cpp | 2 +- {code => src}/p_lnspec.cpp | 33 +- {code => src}/p_lnspec.h | 7 +- {code => src}/p_local.h | 0 {code => src}/p_map.cpp | 132 +- {code => src}/p_maputl.cpp | 5 +- {code => src}/p_mobj.cpp | 331 ++- {code => src}/p_pillar.cpp | 2 +- {code => src}/p_plats.cpp | 0 {code => src}/p_pspr.cpp | 2 +- {code => src}/p_pspr.h | 0 {code => src}/p_saveg.cpp | 7 +- {code => src}/p_saveg.h | 0 {code => src}/p_sectors.cpp | 0 {code => src}/p_setup.cpp | 47 +- {code => src}/p_setup.h | 0 {code => src}/p_sight.cpp | 0 {code => src}/p_spark.cpp | 2 +- {code => src}/p_spec.cpp | 70 +- {code => src}/p_spec.h | 0 {code => src}/p_switch.cpp | 0 {code => src}/p_teleport.cpp | 2 +- {code => src}/p_terrain.cpp | 0 {code => src}/p_terrain.h | 2 +- {code => src}/p_things.cpp | 4 +- {code => src}/p_tick.cpp | 11 - {code => src}/p_tick.h | 0 {code => src}/p_trace.cpp | 2 +- {code => src}/p_trace.h | 2 +- {code => src}/p_user.cpp | 120 +- {code => src}/p_xlat.cpp | 4 +- {code => src}/po_man.cpp | 0 {code => src}/r_bsp.cpp | 352 +-- {code => src}/r_bsp.h | 0 {code => src}/r_data.cpp | 7 +- {code => src}/r_data.h | 0 {code => src}/r_defs.h | 7 +- {code => src}/r_draw.cpp | 163 +- {code => src}/r_draw.h | 6 - {code => src}/r_drawt.cpp | 48 +- {code => src}/r_local.h | 0 {code => src}/r_main.cpp | 86 +- {code => src}/r_main.h | 0 {code => src}/r_plane.cpp | 77 +- {code => src}/r_plane.h | 0 {code => src}/r_segs.cpp | 13 +- {code => src}/r_segs.h | 0 {code => src}/r_sky.cpp | 6 +- {code => src}/r_sky.h | 2 +- {code => src}/r_state.h | 0 {code => src}/r_things.cpp | 138 +- {code => src}/r_things.h | 0 {code => src}/s_advsound.cpp | 35 +- {code => src}/s_playlist.cpp | 30 + {code => src}/s_playlist.h | 4 +- {code => src}/s_sndseq.cpp | 4 +- {code => src}/s_sndseq.h | 2 +- {code => src}/s_sound.cpp | 302 ++- {code => src}/s_sound.h | 25 +- {code => src}/sc_man.cpp | 0 {code => src}/sc_man.h | 2 +- {code => src}/skins.cpp | 2 +- {code => src}/skins.h | 2 +- {code => src}/st_stuff.cpp | 16 +- {code => src}/st_stuff.h | 0 {code => src}/statnums.h | 16 +- {code => src}/stats.cpp | 4 +- {code => src}/stats.h | 0 {code => src}/stringenums.h | 0 {code => src}/stringtable.cpp | 0 {code => src}/stringtable.h | 0 {code => src}/tables.cpp | 2 +- {code => src}/tables.h | 0 {code => src}/tarray.h | 24 + src/tempfiles.cpp | 23 + src/tempfiles.h | 26 + {code => src}/templates.h | 2 +- {code => src}/tmap.nas | 68 +- {code => src}/tmap2.nas | 4 +- {code => src}/v_collection.cpp | 0 {code => src}/v_collection.h | 2 +- {code => src}/v_draw.cpp | 35 +- {code => src}/v_font.cpp | 2 +- {code => src}/v_font.h | 2 +- {code => src}/v_palette.cpp | 15 +- {code => src}/v_palette.h | 0 {code => src}/v_pfx.cpp | 0 {code => src}/v_pfx.h | 2 +- {code => src}/v_text.cpp | 91 +- src/v_text.h | 38 + {code => src}/v_video.cpp | 42 +- {code => src}/v_video.h | 61 +- {code => src}/vectors.cpp | 0 {code => src}/vectors.h | 2 +- {code => src}/version.h | 4 +- {code => src}/w_wad.cpp | 32 +- {code => src}/w_wad.h | 2 +- src/weightedlist.h | 114 + {code => src}/wi_stuff.cpp | 8 +- {code => src}/wi_stuff.h | 0 src/win32/cursor1.cur | Bin 0 -> 326 bytes {code => src}/win32/dxcrap.cpp | 0 {code => src}/win32/hardware.cpp | 16 +- src/win32/hardware.h | 61 + {code => src}/win32/helperthread.cpp | 0 {code => src}/win32/helperthread.h | 2 +- {code => src}/win32/i_cd.cpp | 8 +- {code => src}/win32/i_input.cpp | 244 +- {code => src}/win32/i_input.h | 0 {code => src}/win32/i_main.cpp | 6 +- {code => src}/win32/i_net.cpp | 0 src/win32/i_net.h | 30 + {code => src}/win32/i_system.cpp | 8 +- {code => src}/win32/i_system.h | 10 +- {code => src}/win32/icon1.ico | Bin {code => src}/win32/mid2strm.cpp | 3 +- {code => src}/win32/mid2strm.h | 18 +- {code => src}/win32/mus2strm.cpp | 148 +- src/win32/mus2strm.h | 10 + {code => src}/win32/resource.h | 3 +- {code => src}/win32/win32iface.h | 0 {code => src}/win32/win32video.cpp | 8 +- {code => src}/win32/zdoom.rc | 7 + {code => src}/z_zone.cpp | 0 {code => src}/z_zone.h | 0 {code => src}/zdoom.dsp | 119 +- {code => src}/zdoom.dsw | 0 {code => src}/zlib-1.1.3/ChangeLog | 0 {code => src}/zlib-1.1.3/FAQ | 0 {code => src}/zlib-1.1.3/INDEX | 0 {code => src}/zlib-1.1.3/Makefile | 0 {code => src}/zlib-1.1.3/Makefile.in | 0 {code => src}/zlib-1.1.3/README | 0 {code => src}/zlib-1.1.3/adler32.c | 0 {code => src}/zlib-1.1.3/algorithm.txt | 0 {code => src}/zlib-1.1.3/compress.c | 0 {code => src}/zlib-1.1.3/configure | 0 {code => src}/zlib-1.1.3/crc32.c | 0 {code => src}/zlib-1.1.3/deflate.c | 0 {code => src}/zlib-1.1.3/deflate.h | 0 {code => src}/zlib-1.1.3/descrip.mms | 0 {code => src}/zlib-1.1.3/gzio.c | 0 {code => src}/zlib-1.1.3/infblock.c | 0 {code => src}/zlib-1.1.3/infblock.h | 0 {code => src}/zlib-1.1.3/infcodes.c | 0 {code => src}/zlib-1.1.3/infcodes.h | 0 {code => src}/zlib-1.1.3/inffast.c | 0 {code => src}/zlib-1.1.3/inffast.h | 0 {code => src}/zlib-1.1.3/inffixed.h | 0 {code => src}/zlib-1.1.3/inflate.c | 0 {code => src}/zlib-1.1.3/inftrees.c | 0 {code => src}/zlib-1.1.3/inftrees.h | 0 {code => src}/zlib-1.1.3/infutil.c | 0 {code => src}/zlib-1.1.3/infutil.h | 0 {code => src}/zlib-1.1.3/trees.c | 0 {code => src}/zlib-1.1.3/trees.h | 0 {code => src}/zlib-1.1.3/uncompr.c | 0 {code => src}/zlib-1.1.3/zconf.h | 0 {code => src}/zlib-1.1.3/zlib.dsp | 0 {code => src}/zlib-1.1.3/zlib.h | 0 {code => src}/zlib-1.1.3/zlib.plg | 0 {code => src}/zlib-1.1.3/zutil.c | 0 {code => src}/zlib-1.1.3/zutil.h | 0 418 files changed, 21199 insertions(+), 4683 deletions(-) create mode 100644 Makefile delete mode 100644 code/c_dispatch.h delete mode 100644 code/decallib.cpp delete mode 100644 code/v_text.h delete mode 100644 code/win32/i_music.cpp delete mode 100644 code/win32/mus2strm.h rename {code/docs => docs}/BUILDLIC.TXT (100%) rename {code/docs => docs}/README.Carmack (100%) rename {code/docs => docs}/README.asm (100%) rename {code/docs => docs}/README.gl (100%) rename {code/docs => docs}/classes.txt (98%) create mode 100644 docs/colors.txt create mode 100644 docs/commands.txt rename code/docs/DOOMLIC.TXT => docs/doomlic.txt (100%) create mode 100644 docs/history.txt rename {code/docs => docs}/notes.txt (100%) rename code/docs/Rh-log.txt => docs/rh-log.txt (93%) create mode 100644 docs/zdoom.txt create mode 100644 install rename {code => src}/actor.h (98%) rename {code => src}/am_map.cpp (99%) rename {code => src}/am_map.h (100%) rename {code => src}/autosegs.h (100%) rename {code => src}/autostart.cpp (100%) rename {code => src}/autozend.cpp (100%) rename {code => src}/b_bot.cpp (97%) rename {code => src}/b_bot.h (100%) rename {code => src}/b_func.cpp (98%) rename {code => src}/b_game.cpp (97%) rename {code => src}/b_move.cpp (100%) rename {code => src}/b_think.cpp (94%) rename {code => src}/basicinlines.h (100%) rename {code => src}/blocks.nas (100%) rename {code => src}/c_bind.cpp (65%) rename {code => src}/c_bind.h (88%) rename {code => src}/c_cmds.cpp (84%) rename {code => src}/c_console.cpp (76%) rename {code => src}/c_console.h (86%) rename {code => src}/c_cvars.cpp (94%) rename {code => src}/c_cvars.h (90%) rename {code => src}/c_dispatch.cpp (53%) create mode 100644 src/c_dispatch.h rename {code => src}/cmdlib.cpp (100%) rename {code => src}/cmdlib.h (100%) rename {code => src}/colormatcher.cpp (91%) rename {code => src}/colormatcher.h (88%) rename {code => src}/configfile.cpp (100%) rename {code => src}/configfile.h (98%) rename {code => src}/ct_chat.cpp (84%) rename {code => src}/d_dehacked.cpp (94%) rename {code => src}/d_dehacked.h (81%) rename {code => src}/d_event.h (100%) rename {code => src}/d_gui.h (52%) rename {code => src}/d_items.cpp (99%) rename {code => src}/d_items.h (98%) rename {code => src}/d_main.cpp (98%) rename {code => src}/d_main.h (100%) rename {code => src}/d_net.cpp (99%) rename {code => src}/d_net.h (100%) rename {code => src}/d_netinf.h (97%) rename {code => src}/d_netinfo.cpp (96%) rename {code => src}/d_player.h (99%) rename {code => src}/d_protocol.cpp (99%) rename {code => src}/d_protocol.h (99%) rename {code => src}/d_textur.h (100%) rename {code => src}/d_ticcmd.h (100%) create mode 100644 src/decallib.cpp rename {code => src}/decallib.h (53%) rename {code => src}/dobject.cpp (98%) rename {code => src}/dobject.h (100%) rename {code => src}/doomdata.h (100%) rename {code => src}/doomdef.cpp (100%) rename {code => src}/doomdef.h (95%) rename {code => src}/doomstat.cpp (98%) rename {code => src}/doomstat.h (93%) rename {code => src}/doomtype.h (83%) rename {code => src}/dsectoreffect.cpp (100%) rename {code => src}/dsectoreffect.h (98%) rename {code => src}/dthinker.cpp (98%) rename {code => src}/dthinker.h (99%) rename {code => src}/errors.h (97%) rename {code => src}/f_finale.cpp (99%) rename {code => src}/f_finale.h (100%) rename {code => src}/f_wipe.cpp (99%) rename {code => src}/f_wipe.h (100%) rename {code => src}/farchive.cpp (87%) rename {code => src}/farchive.h (89%) create mode 100644 src/fmodsound/i_music.cpp rename code/win32/I_music.h => src/fmodsound/i_music.h (97%) rename {code/win32 => src/fmodsound}/i_sound.cpp (91%) rename {code/win32 => src/fmodsound}/i_sound.h (98%) rename {code => src}/g_doom/a_arachnotron.cpp (100%) rename {code => src}/g_doom/a_archvile.cpp (100%) rename {code => src}/g_doom/a_bossbrain.cpp (98%) rename {code => src}/g_doom/a_bruiser.cpp (100%) rename {code => src}/g_doom/a_cacodemon.cpp (100%) rename {code => src}/g_doom/a_cyberdemon.cpp (100%) rename {code => src}/g_doom/a_demon.cpp (100%) rename {code => src}/g_doom/a_doomarmor.cpp (100%) rename {code => src}/g_doom/a_doomartifacts.cpp (98%) rename {code => src}/g_doom/a_doomdecorations.cpp (100%) rename {code => src}/g_doom/a_doomglobal.h (97%) rename {code => src}/g_doom/a_doomhealth.cpp (100%) rename {code => src}/g_doom/a_doomimp.cpp (100%) rename {code => src}/g_doom/a_doomkeys.cpp (100%) rename {code => src}/g_doom/a_doommisc.cpp (93%) rename {code => src}/g_doom/a_doomplayer.cpp (99%) rename {code => src}/g_doom/a_doomweaps.cpp (95%) rename {code => src}/g_doom/a_fatso.cpp (100%) rename {code => src}/g_doom/a_keen.cpp (100%) rename {code => src}/g_doom/a_lostsoul.cpp (98%) rename {code => src}/g_doom/a_painelemental.cpp (99%) rename {code => src}/g_doom/a_possessed.cpp (100%) rename {code => src}/g_doom/a_revenant.cpp (100%) rename {code => src}/g_doom/a_spidermaster.cpp (100%) rename {code => src}/g_doom/doom_sbar.cpp (99%) rename {code => src}/g_game.cpp (94%) rename {code => src}/g_game.h (100%) rename {code => src}/g_heretic/a_beast.cpp (100%) rename {code => src}/g_heretic/a_chicken.cpp (100%) rename {code => src}/g_heretic/a_clink.cpp (100%) rename {code => src}/g_heretic/a_dsparil.cpp (100%) rename {code => src}/g_heretic/a_hereticambience.cpp (100%) rename {code => src}/g_heretic/a_hereticarmor.cpp (100%) rename {code => src}/g_heretic/a_hereticartifacts.cpp (100%) rename {code => src}/g_heretic/a_hereticdecorations.cpp (100%) rename {code => src}/g_heretic/a_hereticglobal.h (97%) rename {code => src}/g_heretic/a_hereticimp.cpp (100%) rename {code => src}/g_heretic/a_heretickeys.cpp (100%) rename {code => src}/g_heretic/a_hereticmisc.cpp (99%) rename {code => src}/g_heretic/a_hereticplayer.cpp (98%) rename {code => src}/g_heretic/a_hereticweaps.cpp (97%) rename {code => src}/g_heretic/a_ironlich.cpp (100%) rename {code => src}/g_heretic/a_knight.cpp (100%) rename {code => src}/g_heretic/a_mummy.cpp (100%) rename {code => src}/g_heretic/a_snake.cpp (100%) rename {code => src}/g_heretic/a_wizard.cpp (100%) rename {code => src}/g_heretic/heretic_sbar.cpp (99%) rename {code => src}/g_hexen/__hexentemp.cpp (100%) rename {code => src}/g_hexen/a_bishop.cpp (100%) rename {code => src}/g_hexen/a_debris_and_spike.cpp (100%) rename {code => src}/g_hexen/a_ettin.cpp (100%) rename {code => src}/g_hexen/a_hexendecorations.cpp (100%) rename {code => src}/g_hexen/a_hexenfighter.cpp (99%) rename {code => src}/g_hexen/a_hexenglobal.h (92%) rename {code => src}/g_hexen/a_hexenspecialdecs.cpp (99%) rename {code => src}/g_level.cpp (94%) rename {code => src}/g_level.h (88%) rename {code => src}/g_raven/a_artiegg.cpp (100%) rename {code => src}/g_raven/a_artitele.cpp (98%) rename {code => src}/g_raven/a_minotaur.cpp (100%) rename {code => src}/g_raven/a_ravenambient.cpp (88%) rename {code => src}/g_raven/a_ravenartifacts.cpp (100%) rename {code => src}/g_raven/a_ravenhealth.cpp (100%) rename {code => src}/g_raven/ravenshared.h (90%) rename {code => src}/g_shared/a_action.cpp (100%) rename {code => src}/g_shared/a_action.h (100%) rename {code => src}/g_shared/a_artifacts.cpp (99%) rename {code => src}/g_shared/a_artifacts.h (99%) rename {code => src}/g_shared/a_bridge.cpp (98%) rename {code => src}/g_shared/a_camera.cpp (100%) rename {code => src}/g_shared/a_decals.cpp (76%) rename {code => src}/g_shared/a_fountain.cpp (100%) create mode 100644 src/g_shared/a_lightning.cpp create mode 100644 src/g_shared/a_lightning.h rename {code => src}/g_shared/a_movingcamera.cpp (100%) rename {code => src}/g_shared/a_pickups.cpp (94%) rename {code => src}/g_shared/a_pickups.h (96%) rename {code => src}/g_shared/a_quake.cpp (99%) rename {code => src}/g_shared/a_secrettrigger.cpp (100%) rename {code => src}/g_shared/a_sectoraction.cpp (100%) rename {code => src}/g_shared/a_sharedglobal.h (90%) rename {code => src}/g_shared/a_sharedmisc.cpp (100%) rename {code => src}/g_shared/a_skies.cpp (100%) rename {code => src}/g_shared/a_splashes.cpp (100%) rename {code => src}/g_shared/a_waterzone.cpp (100%) rename {code => src}/g_shared/a_weapons.cpp (79%) rename {code => src}/g_shared/hudmessages.cpp (98%) rename {code => src}/g_shared/sbar.h (95%) rename {code => src}/g_shared/shared_sbar.cpp (95%) rename {code => src}/gameconfigfile.cpp (94%) rename {code => src}/gameconfigfile.h (95%) rename {code => src}/gccinlines.h (94%) rename {code => src}/gi.cpp (97%) rename {code => src}/gi.h (95%) rename {code => src}/gstrings.h (91%) rename {code => src}/hu_stuff.h (100%) rename {code/win32 => src}/i_cd.h (98%) rename {code/win32 => src}/i_video.h (100%) rename {code => src}/info.cpp (96%) rename {code => src}/info.h (99%) rename {code => src}/infodefaults.cpp (95%) rename {code => src}/infomacros.h (97%) create mode 100644 src/linux/Makefile create mode 100644 src/linux/dikeys.h create mode 100644 src/linux/expandorama.h create mode 100644 src/linux/expandorama.nas create mode 100644 src/linux/files.mak create mode 100644 src/linux/hardware.cpp rename {code/win32 => src/linux}/hardware.h (100%) create mode 100644 src/linux/hw_svgalib.cpp create mode 100644 src/linux/hw_x.cpp create mode 100644 src/linux/i_cd.cpp create mode 100644 src/linux/i_input.cpp create mode 100644 src/linux/i_input.h create mode 100644 src/linux/i_main.cpp create mode 100644 src/linux/i_music.cpp create mode 100644 src/linux/i_music.h create mode 100644 src/linux/i_net.cpp rename {code/win32 => src/linux}/i_net.h (100%) create mode 100644 src/linux/i_sound.cpp create mode 100644 src/linux/i_system.cpp create mode 100644 src/linux/i_system.h create mode 100644 src/linux/i_video.h create mode 100644 src/linux/nullvideo.cpp create mode 100644 src/linux/nullvideo.h create mode 100644 src/linux/sdlvideo.cpp create mode 100644 src/linux/sdlvideo.h rename {code => src}/lists.h (98%) rename {code => src}/lumpconfigfile.cpp (100%) rename {code => src}/lumpconfigfile.h (93%) rename {code => src}/m_alloc.cpp (67%) rename {code => src}/m_alloc.h (93%) rename {code => src}/m_argv.cpp (100%) rename {code => src}/m_argv.h (98%) rename {code => src}/m_bbox.cpp (100%) rename {code => src}/m_bbox.h (98%) rename {code => src}/m_cheat.cpp (96%) rename {code => src}/m_cheat.h (100%) create mode 100644 src/m_crc32.h rename {code => src}/m_fixed.cpp (100%) rename {code => src}/m_fixed.h (99%) rename {code => src}/m_menu.cpp (91%) rename {code => src}/m_menu.h (98%) rename {code => src}/m_misc.cpp (77%) rename {code => src}/m_misc.h (98%) rename {code => src}/m_options.cpp (98%) rename {code => src}/m_random.cpp (100%) rename {code => src}/m_random.h (98%) rename {code => src}/m_swap.h (100%) rename {code => src}/misc.nas (64%) rename {code => src}/mscinlines.h (100%) create mode 100644 src/mus2midi.cpp create mode 100644 src/mus2midi.h rename {code => src}/p_acs.cpp (99%) rename {code => src}/p_acs.h (99%) rename {code => src}/p_ceiling.cpp (98%) rename {code => src}/p_doors.cpp (100%) rename {code => src}/p_effect.cpp (99%) rename {code => src}/p_effect.h (95%) rename {code => src}/p_enemy.cpp (96%) rename {code => src}/p_enemy.h (98%) rename {code => src}/p_floor.cpp (100%) rename {code => src}/p_inter.h (94%) rename {code => src}/p_interaction.cpp (96%) rename {code => src}/p_lights.cpp (99%) rename {code => src}/p_lnspec.cpp (98%) rename {code => src}/p_lnspec.h (98%) rename {code => src}/p_local.h (100%) rename {code => src}/p_map.cpp (96%) rename {code => src}/p_maputl.cpp (99%) rename {code => src}/p_mobj.cpp (93%) rename {code => src}/p_pillar.cpp (99%) rename {code => src}/p_plats.cpp (100%) rename {code => src}/p_pspr.cpp (99%) rename {code => src}/p_pspr.h (100%) rename {code => src}/p_saveg.cpp (97%) rename {code => src}/p_saveg.h (100%) rename {code => src}/p_sectors.cpp (100%) rename {code => src}/p_setup.cpp (98%) rename {code => src}/p_setup.h (100%) rename {code => src}/p_sight.cpp (100%) rename {code => src}/p_spark.cpp (99%) rename {code => src}/p_spec.cpp (97%) rename {code => src}/p_spec.h (100%) rename {code => src}/p_switch.cpp (100%) rename {code => src}/p_teleport.cpp (99%) rename {code => src}/p_terrain.cpp (100%) rename {code => src}/p_terrain.h (97%) rename {code => src}/p_things.cpp (94%) rename {code => src}/p_tick.cpp (86%) rename {code => src}/p_tick.h (100%) rename {code => src}/p_trace.cpp (99%) rename {code => src}/p_trace.h (97%) rename {code => src}/p_user.cpp (93%) rename {code => src}/p_xlat.cpp (99%) rename {code => src}/po_man.cpp (100%) rename {code => src}/r_bsp.cpp (73%) rename {code => src}/r_bsp.h (100%) rename {code => src}/r_data.cpp (99%) rename {code => src}/r_data.h (100%) rename {code => src}/r_defs.h (98%) rename {code => src}/r_draw.cpp (91%) rename {code => src}/r_draw.h (97%) rename {code => src}/r_drawt.cpp (97%) rename {code => src}/r_local.h (100%) rename {code => src}/r_main.cpp (96%) rename {code => src}/r_main.h (100%) rename {code => src}/r_plane.cpp (95%) rename {code => src}/r_plane.h (100%) rename {code => src}/r_segs.cpp (99%) rename {code => src}/r_segs.h (100%) rename {code => src}/r_sky.cpp (95%) rename {code => src}/r_sky.h (98%) rename {code => src}/r_state.h (100%) rename {code => src}/r_things.cpp (94%) rename {code => src}/r_things.h (100%) rename {code => src}/s_advsound.cpp (97%) rename {code => src}/s_playlist.cpp (87%) rename {code => src}/s_playlist.h (88%) rename {code => src}/s_sndseq.cpp (99%) rename {code => src}/s_sndseq.h (99%) rename {code => src}/s_sound.cpp (90%) rename {code => src}/s_sound.h (91%) rename {code => src}/sc_man.cpp (100%) rename {code => src}/sc_man.h (97%) rename {code => src}/skins.cpp (99%) rename {code => src}/skins.h (66%) rename {code => src}/st_stuff.cpp (97%) rename {code => src}/st_stuff.h (100%) rename {code => src}/statnums.h (50%) rename {code => src}/stats.cpp (95%) rename {code => src}/stats.h (100%) rename {code => src}/stringenums.h (100%) rename {code => src}/stringtable.cpp (100%) rename {code => src}/stringtable.h (100%) rename {code => src}/tables.cpp (95%) rename {code => src}/tables.h (100%) rename {code => src}/tarray.h (75%) create mode 100644 src/tempfiles.cpp create mode 100644 src/tempfiles.h rename {code => src}/templates.h (99%) rename {code => src}/tmap.nas (95%) rename {code => src}/tmap2.nas (99%) rename {code => src}/v_collection.cpp (100%) rename {code => src}/v_collection.h (96%) rename {code => src}/v_draw.cpp (98%) rename {code => src}/v_font.cpp (99%) rename {code => src}/v_font.h (98%) rename {code => src}/v_palette.cpp (98%) rename {code => src}/v_palette.h (100%) rename {code => src}/v_pfx.cpp (100%) rename {code => src}/v_pfx.h (97%) rename {code => src}/v_text.cpp (76%) create mode 100644 src/v_text.h rename {code => src}/v_video.cpp (96%) rename {code => src}/v_video.h (91%) rename {code => src}/vectors.cpp (100%) rename {code => src}/vectors.h (98%) rename {code => src}/version.h (82%) rename {code => src}/w_wad.cpp (97%) rename {code => src}/w_wad.h (97%) create mode 100644 src/weightedlist.h rename {code => src}/wi_stuff.cpp (99%) rename {code => src}/wi_stuff.h (100%) create mode 100644 src/win32/cursor1.cur rename {code => src}/win32/dxcrap.cpp (100%) rename {code => src}/win32/hardware.cpp (93%) create mode 100644 src/win32/hardware.h rename {code => src}/win32/helperthread.cpp (100%) rename {code => src}/win32/helperthread.h (97%) rename {code => src}/win32/i_cd.cpp (99%) rename {code => src}/win32/i_input.cpp (86%) rename {code => src}/win32/i_input.h (100%) rename {code => src}/win32/i_main.cpp (95%) rename {code => src}/win32/i_net.cpp (100%) create mode 100644 src/win32/i_net.h rename {code => src}/win32/i_system.cpp (98%) rename {code => src}/win32/i_system.h (93%) rename {code => src}/win32/icon1.ico (100%) rename {code => src}/win32/mid2strm.cpp (99%) rename {code => src}/win32/mid2strm.h (68%) rename {code => src}/win32/mus2strm.cpp (71%) create mode 100644 src/win32/mus2strm.h rename {code => src}/win32/resource.h (90%) rename {code => src}/win32/win32iface.h (100%) rename {code => src}/win32/win32video.cpp (99%) rename {code => src}/win32/zdoom.rc (96%) rename {code => src}/z_zone.cpp (100%) rename {code => src}/z_zone.h (100%) rename {code => src}/zdoom.dsp (93%) rename {code => src}/zdoom.dsw (100%) rename {code => src}/zlib-1.1.3/ChangeLog (100%) rename {code => src}/zlib-1.1.3/FAQ (100%) rename {code => src}/zlib-1.1.3/INDEX (100%) rename {code => src}/zlib-1.1.3/Makefile (100%) rename {code => src}/zlib-1.1.3/Makefile.in (100%) rename {code => src}/zlib-1.1.3/README (100%) rename {code => src}/zlib-1.1.3/adler32.c (100%) rename {code => src}/zlib-1.1.3/algorithm.txt (100%) rename {code => src}/zlib-1.1.3/compress.c (100%) rename {code => src}/zlib-1.1.3/configure (100%) rename {code => src}/zlib-1.1.3/crc32.c (100%) rename {code => src}/zlib-1.1.3/deflate.c (100%) rename {code => src}/zlib-1.1.3/deflate.h (100%) rename {code => src}/zlib-1.1.3/descrip.mms (100%) rename {code => src}/zlib-1.1.3/gzio.c (100%) rename {code => src}/zlib-1.1.3/infblock.c (100%) rename {code => src}/zlib-1.1.3/infblock.h (100%) rename {code => src}/zlib-1.1.3/infcodes.c (100%) rename {code => src}/zlib-1.1.3/infcodes.h (100%) rename {code => src}/zlib-1.1.3/inffast.c (100%) rename {code => src}/zlib-1.1.3/inffast.h (100%) rename {code => src}/zlib-1.1.3/inffixed.h (100%) rename {code => src}/zlib-1.1.3/inflate.c (100%) rename {code => src}/zlib-1.1.3/inftrees.c (100%) rename {code => src}/zlib-1.1.3/inftrees.h (100%) rename {code => src}/zlib-1.1.3/infutil.c (100%) rename {code => src}/zlib-1.1.3/infutil.h (100%) rename {code => src}/zlib-1.1.3/trees.c (100%) rename {code => src}/zlib-1.1.3/trees.h (100%) rename {code => src}/zlib-1.1.3/uncompr.c (100%) rename {code => src}/zlib-1.1.3/zconf.h (100%) rename {code => src}/zlib-1.1.3/zlib.dsp (100%) rename {code => src}/zlib-1.1.3/zlib.h (100%) rename {code => src}/zlib-1.1.3/zlib.plg (100%) rename {code => src}/zlib-1.1.3/zutil.c (100%) rename {code => src}/zlib-1.1.3/zutil.h (100%) diff --git a/Makefile b/Makefile new file mode 100644 index 0000000000..d081810be1 --- /dev/null +++ b/Makefile @@ -0,0 +1,172 @@ +#################################################################### +# +# Makefile for ZDoom. This probably requires GNU Make. +# +#################################################################### + +CC = gcc -V3.0 +CXX = g++ -V3.0 +AS = nasm +RM = rm -f +RMTREE = rm -R +RMDIR = rmdir +CP = cp +LD = ld +INSTALL = install +ECHO = echo +TAR = tar +GZIP = gzip + +basename = zdoom-1.23 + +# the OS type we are building for; should match a directory in src_dir +SYSTEM = linux + +# distribution names +BINTAR = $(basename)-i586.tar.gz +SRCTAR = $(basename).tar.gz + +# options common to all builds +prefix = /usr/local +lib_dir = $(prefix)/lib +bin_dir = $(prefix)/bin +doc_dir = $(prefix)/doc/zdoom +share_dir = $(prefix)/share +zdoomshare_dir = $(share_dir)/zdoom +X_libs = /usr/X11R6/lib +src_dir = src + +IMPDIR = $(src_dir)/$(SYSTEM) +mode = release + +# directory to hold all intermediate files +INTDIR = $(IMPDIR)/$(mode) + +SRCDOC = INSTALL README +CPPFLAGS_common = -Wall -Winline -I$(src_dir) -I$(src_dir)/fmodsound -I$(IMPDIR) \ + -I$(src_dir)/g_shared -I$(src_dir)/g_doom -I$(src_dir)/g_raven \ + -I$(src_dir)/g_heretic -I$(src_dir)/g_hexen -Ifmod/api/inc +OUTFILE = zdoom + +zdoom doom release all: $(INTDIR)/$(OUTFILE) + +include $(IMPDIR)/files.mak + +# options specific to the debug build +CPPFLAGS_debug = -g -Wp,-DRANGECHECK +LDFLAGS_debug = +ASFLAGS_debug = -g +DEFS_debug = -Wp,-DDEBUG,-DUSEASM # -DNOASM + +# options specific to the release build +CPPFLAGS_release = -O2 -march=pentium -fomit-frame-pointer +LDFLAGS_release = -s +ASFLAGS_release = +DEFS_release = -Wp,-DNDEBUG,-DUSEASM + +# select flags for this build +CPPFLAGS = $(CPPFLAGS_common) $(CPPFLAGS_$(mode)) \ + $(DEFS_common) $(DEFS_$(mode)) +LDFLAGS = $(LDFLAGS_common) $(LDFLAGS_$(mode)) +ASFLAGS = $(ASFLAGS_common) $(ASFLAGS_$(mode)) + +# directory to get dependency files +DEPSDIR = deps + +# pull in common object and source files extracted from zdoom.dsp +include dspfiles + +# object files +OBJS = $(DSPOBJS) $(SYSOBJS) + +# all dependency directories +DEPSDIRS = $(DSPDEPSDIRS) $(DEPSDIR)/$(SYSTEM) + +ALLSOURCES = $(DSPSOURCES) $(SOURCES) $(HWSOURCES) + +DSPDEPS = $(patsubst $(src_dir)/%.cpp,$(DEPSDIR)/%.d, \ + $(filter %.cpp %.c,$(DSPSOURCES))) +SYSDEPS = $(patsubst $(src_dir)/%.cpp,$(DEPSDIR)/%.d, \ + $(filter %.cpp %.c,$(SYSSOURCES))) + +# If the VC++ project file changes, remake our list of source files +dspfiles: $(src_dir)/zdoom.dsp util/cvdsp + util/cvdsp $(src_dir)/zdoom.dsp > dspfiles + +util/cvdsp: util/cvdsp.c + $(CC) util/cvdsp.c -o util/cvdsp -s -O + +debug: + $(MAKE) mode=debug + +clean: + $(RMTREE) $(IMPDIR)/release + $(RMTREE) $(IMPDIR)/debug + $(RMTREE) $(DEPSDIR) + +$(INTDIR)/$(OUTFILE): common sysspecific + $(CXX) $(LDFLAGS) $(OBJS) -o $@ $(LIBS) + +common: $(DSPINTDIRS) $(DSPDEPS) $(DSPOBJS) + +sysspecific: $(INTDIR)/$(SYSTEM) $(SYSDEPS) $(SYSOBJS) + +# Compile .cpp files +$(INTDIR)/%.o: $(src_dir)/%.cpp + $(CXX) $(CPPFLAGS) -c $< -o $@ + +# Assemble .nas files +$(INTDIR)/%.o: $(src_dir)/%.nas + $(AS) $(ASFLAGS) -o $@ $< + +# Make intermediate directories +$(INTDIR): + mkdir -p $@ + +$(INTDIR)/%: + mkdir -p $@ + +#$(INTDIR)/%.o: $(IMPDIR)/%.nas +# $(AS) $(ASFLAGS) -o $@ $< + +#$(INTDIR)/%.o: $(IMPDIR)/%.cpp +# $(CXX) $(CPPFLAGS) -c $< -o $@ + +# Create dependency files +$(DEPSDIR)/%.d: $(src_dir)/%.cpp + mkdir -p $(DEPSDIRS) + $(SHELL) -ec '$(CXX) -MM $(CPPFLAGS_common) $(DEFS_common) $< \ + | sed '\''s/\($(*F)\)\.o[ :]*/$$\(INTDIR\)\/\1.o $(subst /,\/,$(@D))\/$(@F) : /g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +include $(DSPDEPS) +include $(SYSDEPS) + +# Create a binary tarball +bintar: install + $(TAR) -cv \ + $(bin_dir)/$(OUTFILE) \ + $(lib_dir)/libzdoom-x.so \ + $(lib_dir)/libzdoom-svgalib.so \ + $(zdoomshare_dir)/zdoom.wad \ + $(zdoomshare_dir)/xkeys \ + $(zdoomshare_dir)/bots.cfg \ + $(zdoomshare_dir)/railgun.bex \ + $(doc_dir)/* \ + | $(GZIP) -9c > $(BINTAR) + +# Create a source tarball +srctar: $(ALLSOURCES) Makefile $(SRCDOC) docs/* other/* + $(SHELL) -ec 'cd ..; \ + $(TAR) -cv --no-recursion --exclude=*.d --exclude=*~\ + $(basename)/Makefile \ + $(basename)/docs/* \ + $(basename)/other/* \ + $(basename)/$(src_dir)/* \ + $(basename)/$(src_dir)/linux/* \ + $(basename)/$(src_dir)/win32/* \ + $(SRCDOC:%=$(basename)/%) \ + | $(GZIP) -9c > $(basename)/$(SRCTAR)' + +srcbz2: srctar + $(GZIP) -cd $(SRCTAR) | bzip2 -9c > $(basename).tar.bz2 diff --git a/code/c_dispatch.h b/code/c_dispatch.h deleted file mode 100644 index d1837d1a7c..0000000000 --- a/code/c_dispatch.h +++ /dev/null @@ -1,98 +0,0 @@ -#ifndef __C_DISPATCH_H__ -#define __C_DISPATCH_H__ - -#include "dobject.h" - -class FConfigFile; - -#define HASH_SIZE 251 // I think this is prime - -void C_ExecCmdLineParams (); - -// add commands to the console as if they were typed in -// for map changing, etc -void AddCommandString (char *text); - -// Write out alias commands to a file for all current aliases. -void C_ArchiveAliases (FConfigFile *f); - -void C_SetAlias (const char *name, const char *cmd); - -// build a single string out of multiple strings -char *BuildString (int argc, char **argv); - -typedef void (*CCmdRun) (int argc, char **argv, const char *args, AActor *instigator); - -class FConsoleCommand -{ -public: - FConsoleCommand (const char *name, CCmdRun RunFunc); - virtual ~FConsoleCommand (); - virtual bool IsAlias (); - void PrintCommand () { Printf ("%s\n", m_Name); } - - virtual void Run (int argc, char **argv, const char *args, AActor *instigator); - - FConsoleCommand *m_Next, **m_Prev; - char *m_Name; - -protected: - FConsoleCommand (); - bool AddToHash (FConsoleCommand **table); - - CCmdRun m_RunFunc; - - friend void C_DoCommand (char *cmd); -}; - -#define CCMD(n) \ - void Cmd_##n (int, char **, const char *, AActor *); \ - FConsoleCommand Cmd_##n##_ (#n, Cmd_##n); \ - void Cmd_##n (int argc, char **argv, const char *args, AActor *m_Instigator) - -class FConsoleAlias : public FConsoleCommand -{ -public: - FConsoleAlias (const char *name, const char *command); - ~FConsoleAlias (); - void Run (int argc, char **argv, const char *args, AActor *m_Instigator); - bool IsAlias (); - void PrintAlias () { Printf ("%s : %s\n", m_Name, m_Command); } - void Archive (FConfigFile *f); -protected: - char *m_Command; -}; - -// Actions -#define ACTION_MLOOK 0 -#define ACTION_KLOOK 1 -#define ACTION_USE 2 -#define ACTION_ATTACK 3 -#define ACTION_SPEED 4 -#define ACTION_MOVERIGHT 5 -#define ACTION_MOVELEFT 6 -#define ACTION_STRAFE 7 -#define ACTION_LOOKDOWN 8 -#define ACTION_LOOKUP 9 -#define ACTION_BACK 10 -#define ACTION_FORWARD 11 -#define ACTION_RIGHT 12 -#define ACTION_LEFT 13 -#define ACTION_MOVEDOWN 14 -#define ACTION_MOVEUP 15 -#define ACTION_JUMP 16 -#define ACTION_SHOWSCORES 17 -#define NUM_ACTIONS 18 - -extern byte Actions[NUM_ACTIONS]; - -struct ActionBits -{ - unsigned int key; - int index; - char name[12]; -}; - -extern unsigned int MakeKey (const char *s); - -#endif //__C_DISPATCH_H__ diff --git a/code/decallib.cpp b/code/decallib.cpp deleted file mode 100644 index bcb81b0443..0000000000 --- a/code/decallib.cpp +++ /dev/null @@ -1,403 +0,0 @@ -#include "decallib.h" -#include "sc_man.h" -#include "w_wad.h" -#include "v_video.h" -#include "v_palette.h" -#include "cmdlib.h" - -FDecalLib DecalLibrary; - -struct FDecalLib::FTranslation -{ - FTranslation (DWORD start, DWORD end); - FTranslation *LocateTranslation (DWORD start, DWORD end); - - DWORD StartColor, EndColor; - FTranslation *Next; - BYTE PalRemap[256]; -}; - -static const char *DecalKeywords[] = -{ - "x-scale", - "y-scale", - "pic", - "translucency", - "flipx", - "flipy", - "fullbright", - "fuzzy", - "shade", - "colors", - NULL -}; - -enum -{ - DECAL_XSCALE, - DECAL_YSCALE, - DECAL_PIC, - DECAL_TRANSLUCENCY, - DECAL_FLIPX, - DECAL_FLIPY, - DECAL_FULLBRIGHT, - DECAL_FUZZY, - DECAL_SHADE, - DECAL_COLORS -}; - -FDecalLib::FDecalLib () -{ - Root = NULL; - Translations = NULL; -} - -FDecalLib::~FDecalLib () -{ - Clear (); -} - -void FDecalLib::Clear () -{ - FTranslation *trans; - - DelTree (Root); - Root = NULL; - - trans = Translations; - while (trans != NULL) - { - FTranslation *next = trans->Next; - delete trans; - trans = next; - } -} - -void FDecalLib::DelTree (FDecal *root) -{ - if (root != NULL) - { - DelTree (root->Left); - DelTree (root->Right); - delete root; - } -} - -void FDecalLib::ReadAllDecals () -{ - int lump, lastlump = 0; - - while ((lump = W_FindLump ("DECALDEF", &lastlump)) != -1) - { - SC_OpenLumpNum (lump, "DECALDEF"); - ReadDecals (); - SC_Close (); - } -} - -void FDecalLib::ReadDecals () -{ - char decalName[64]; - byte decalNum; - FDecal newdecal; - int code; - - while (SC_GetString ()) - { - if (!SC_Compare ("decal")) - { - SC_ScriptError (NULL); - } - SC_MustGetString (); - strcpy (decalName, sc_String); - SC_MustGetString (); - if (!IsNum (sc_String)) - { - SC_UnGet (); - decalNum = 0; - } - else - { - unsigned long num = strtoul (sc_String, NULL, 10); - if (num < 1 || num > 255) - { - SC_ScriptError ("Decal ID must be between 1 and 255"); - } - decalNum = (byte)num; - } - SC_MustGetStringName ("{"); - - memset (&newdecal, 0, sizeof(newdecal)); - newdecal.PicNum = 0xffff; - newdecal.ScaleX = newdecal.ScaleY = 63; - newdecal.RenderFlags = RF_WALLSPRITE; - newdecal.RenderStyle = STYLE_Translucent; - newdecal.Alpha = 0x8000; - - for (;;) - { - SC_GetString (); - if (SC_Compare ("}")) - { - AddDecal (decalName, decalNum, newdecal); - break; - } - switch ((code = SC_MustMatchString (DecalKeywords))) - { - case DECAL_XSCALE: - case DECAL_YSCALE: - SC_MustGetNumber (); - if (--sc_Number < 0) - sc_Number = 0; - if (sc_Number > 255) - sc_Number = 255; - if (code == DECAL_XSCALE) - newdecal.ScaleX = sc_Number; - else - newdecal.ScaleY = sc_Number; - break; - - case DECAL_PIC: - SC_MustGetString (); - newdecal.PicNum = R_CheckTileNumForName (sc_String, TILE_Patch); - break; - - case DECAL_TRANSLUCENCY: - SC_MustGetFloat (); - newdecal.Alpha = (WORD)(32768.f * sc_Float); - break; - - case DECAL_FLIPX: - newdecal.RenderFlags |= RF_XFLIP; - break; - - case DECAL_FLIPY: - newdecal.RenderFlags |= RF_YFLIP; - break; - - case DECAL_FULLBRIGHT: - newdecal.RenderFlags |= RF_FULLBRIGHT; - break; - - case DECAL_FUZZY: - newdecal.RenderStyle = STYLE_Fuzzy; - break; - - case DECAL_SHADE: - SC_MustGetString (); - newdecal.RenderStyle = STYLE_Shaded; - newdecal.ShadeColor = V_GetColor (NULL, sc_String); - newdecal.ShadeColor |= - ColorMatcher.Pick (RPART(newdecal.ShadeColor), - GPART(newdecal.ShadeColor), BPART(newdecal.ShadeColor)) << 24; - break; - - case DECAL_COLORS: - DWORD startcolor, endcolor; - - SC_MustGetString (); startcolor = V_GetColor (NULL, sc_String); - SC_MustGetString (); endcolor = V_GetColor (NULL, sc_String); - newdecal.Translation = GenerateTranslation (startcolor, endcolor)->PalRemap; - break; - } - } - } -} - -void FDecalLib::AddDecal (const char *name, byte num, const FDecal &decal) -{ - FDecal *node = Root, **prev = &Root; - - while (node != NULL) - { - int lexx = stricmp (name, node->Name); - if (lexx == 0) - { - break; - } - else if (lexx < 0) - { - prev = &node->Left; - node = node->Left; - } - else - { - prev = &node->Right; - node = node->Right; - } - } - if (node == NULL) - { - node = new FDecal; - *node = decal; - node->Name = copystring (name); - node->SpawnID = num; - node->Left = node->Right = NULL; - *prev = node; - } - else - { - char *savename = node->Name; - *node = decal; - node->Name = savename; - node->SpawnID = num; - } - if (num != 0) - { - FDecal *spawner = ScanTreeForNum (num, Root); - if (spawner != node) - { - spawner->SpawnID = 0; - } - } -} - -const FDecal *FDecalLib::GetDecalByNum (byte num) const -{ - if (num == 0) - { - return NULL; - } - FDecal *node = ScanTreeForNum (num, Root); - return node; -} - -const FDecal *FDecalLib::GetDecalByName (const char *name) const -{ - if (name == NULL) - { - return NULL; - } - FDecal *node = ScanTreeForName (name, Root); - return node; -} - -FDecal *FDecalLib::ScanTreeForNum (const BYTE num, FDecal *root) -{ - while (root != NULL) - { - if (root->SpawnID == num) - { - break; - } - ScanTreeForNum (num, root->Left); - root = root->Right; // Avoid tail-recursion - } - return root; -} - -FDecal *FDecalLib::ScanTreeForName (const char *name, FDecal *root) -{ - while (root != NULL) - { - int lexx = stricmp (name, root->Name); - if (lexx == 0) - { - break; - } - else if (lexx < 0) - { - root = root->Left; - } - else - { - root = root->Right; - } - } - return root; -} - -FDecalLib::FTranslation *FDecalLib::GenerateTranslation (DWORD start, DWORD end) -{ - FTranslation *trans; - - if (Translations != NULL) - { - trans = Translations->LocateTranslation (start, end); - } - else - { - trans = NULL; - } - if (trans == NULL) - { - trans = new FTranslation (start, end); - trans->Next = Translations; - Translations = trans; - } - return trans; -} - -FDecal::FDecal () -{ - Name = NULL; - Translation = NULL; -} - -FDecal::~FDecal () -{ - if (Name != NULL) - delete[] Name; -} - -void FDecal::ApplyToActor (AActor *actor) const -{ - if (RenderStyle == STYLE_Shaded) - { - actor->SetShade (ShadeColor); - } - actor->translation = Translation; - actor->xscale = ScaleX; - actor->yscale = ScaleY; - actor->picnum = PicNum; - actor->renderflags = RenderFlags | - (actor->renderflags & (RF_RELMASK|RF_CLIPMASK|RF_INVISIBLE|RF_ONESIDED)); - actor->alpha = Alpha << 1; - actor->RenderStyle = RenderStyle; -} - -FDecalLib::FTranslation::FTranslation (DWORD start, DWORD end) -{ - DWORD ri, gi, bi, rs, gs, bs; - PalEntry *first, *last; - int i; - - StartColor = start; - EndColor = end; - Next = NULL; - - first = (PalEntry *)&StartColor; - last = (PalEntry *)&EndColor; - - ri = first->r << 24; - gi = first->g << 24; - bi = first->b << 24; - rs = last->r << 24; - gs = last->g << 24; - bs = last->b << 24; - - rs = (rs - ri) / 255; - gs = (gs - ri) / 255; - bs = (bs - bi) / 255; - - for (i = 1; i < 256; i++, ri += rs, gi += gs, bi += bs) - { - PalRemap[i] = ColorMatcher.Pick (ri >> 24, gi >> 24, bi >> 24); - } - PalRemap[0] = PalRemap[1]; -} - -FDecalLib::FTranslation *FDecalLib::FTranslation::LocateTranslation (DWORD start, DWORD end) -{ - FTranslation *trans = this; - - do - { - if (start == trans->StartColor && end == trans->EndColor) - { - return trans; - } - trans = trans->Next; - } while (trans != NULL); - return trans; -} diff --git a/code/v_text.h b/code/v_text.h deleted file mode 100644 index 31f65c4bd7..0000000000 --- a/code/v_text.h +++ /dev/null @@ -1,38 +0,0 @@ -#ifndef __V_TEXT_H__ -#define __V_TEXT_H__ - -#include "doomtype.h" -#include "v_font.h" - -struct brokenlines_s { - short width; - byte nlterminated; - byte pad; - char *string; -}; -typedef struct brokenlines_s brokenlines_t; - -#define TEXTCOLOR_ESCAPE '\x81' - -#define TEXTCOLOR_BRICK "\x81""A" -#define TEXTCOLOR_TAN "\x81""B" -#define TEXTCOLOR_GRAY "\x81""C" -#define TEXTCOLOR_GREY "\x81""C" -#define TEXTCOLOR_GREEN "\x81""D" -#define TEXTCOLOR_BROWN "\x81""E" -#define TEXTCOLOR_GOLD "\x81""F" -#define TEXTCOLOR_RED "\x81""G" -#define TEXTCOLOR_BLUE "\x81""H" -#define TEXTCOLOR_ORANGE "\x81""I" -#define TEXTCOLOR_WHITE "\x81""J" -#define TEXTCOLOR_YELLOW "\x81""k" - -#define TEXTCOLOR_NORMAL "\x81-" -#define TEXTCOLOR_BOLD "\x81+" - -brokenlines_t *V_BreakLines (int maxwidth, const byte *str, bool keepspace=false); -void V_FreeBrokenLines (brokenlines_t *lines); -inline brokenlines_t *V_BreakLines (int maxwidth, const char *str, bool keepspace=false) - { return V_BreakLines (maxwidth, (const byte *)str, keepspace); } - -#endif //__V_TEXT_H__ \ No newline at end of file diff --git a/code/win32/i_music.cpp b/code/win32/i_music.cpp deleted file mode 100644 index 1c81a6530b..0000000000 --- a/code/win32/i_music.cpp +++ /dev/null @@ -1,1062 +0,0 @@ -#define WIN32_LEAN_AND_MEAN -#include -#include -#include -#include - -#include "doomtype.h" -#include "m_argv.h" -#include "i_music.h" -#include "w_wad.h" -#include "c_console.h" -#include "c_dispatch.h" -#include "z_zone.h" -#include "mid2strm.h" -#include "mus2strm.h" -#include "i_system.h" -#include "i_sound.h" -#include "i_cd.h" - -#include - -EXTERN_CVAR (Int, snd_musicvolume) -extern int _nosound; - -class MusInfo -{ -public: - MusInfo () { m_Status = STATE_Stopped; } - virtual ~MusInfo () {} - virtual void SetVolume (float volume) = 0; - virtual void Play (bool looping) = 0; - virtual void Pause () = 0; - virtual void Resume () = 0; - virtual void Stop () = 0; - virtual bool IsPlaying () = 0; - virtual bool IsMIDI () = 0; - virtual bool IsValid () = 0; - virtual bool SetPosition (int order) { return false; } - - enum EState - { - STATE_Stopped, - STATE_Playing, - STATE_Paused - } m_Status; - bool m_Looping; -}; - -class MIDISong : public MusInfo -{ -public: - MIDISong (int handle, int pos, int len); - ~MIDISong (); - void SetVolume (float volume); - void Play (bool looping); - void Pause (); - void Resume (); - void Stop (); - bool IsPlaying (); - bool IsMIDI () { return true; } - bool IsValid () { return m_Buffers != NULL; } - void MidiProc (UINT uMsg); - -protected: - MIDISong (); - void MCIError (MMRESULT res, const char *descr); - void UnprepareHeaders (); - bool PrepareHeaders (); - void SubmitBuffer (); - void AllChannelsOff (); - - bool m_IsMUS; - - enum - { - cb_play, - cb_die, - cb_dead - } m_CallbackStatus; - HMIDISTRM m_MidiStream; - PSTREAMBUF m_Buffers; - PSTREAMBUF m_CurrBuffer; -}; - -class MUSSong : public MIDISong -{ -public: - MUSSong (int handle, int pos, int len); -}; - -class MODSong : public MusInfo -{ -public: - MODSong (int handle, int pos, int len); - ~MODSong (); - void SetVolume (float volume); - void Play (bool looping); - void Pause (); - void Resume (); - void Stop (); - bool IsPlaying (); - bool IsMIDI () { return false; } - bool IsValid () { return m_Module != NULL; } - bool SetPosition (int order); - -protected: - FMUSIC_MODULE *m_Module; -}; - -class StreamSong : public MusInfo -{ -public: - StreamSong (int handle, int pos, int len); - ~StreamSong (); - void SetVolume (float volume); - void Play (bool looping); - void Pause (); - void Resume (); - void Stop (); - bool IsPlaying (); - bool IsMIDI () { return false; } - bool IsValid () { return m_Stream != NULL; } - -protected: - FSOUND_STREAM *m_Stream; - int m_Channel; - int m_Length; - int m_LastPos; - - static int m_Volume; -}; - -int StreamSong::m_Volume = 255; - -class CDSong : public MusInfo -{ -public: - CDSong (int track, int id); - ~CDSong (); - void SetVolume (float volume) {} - void Play (bool looping); - void Pause (); - void Resume (); - void Stop (); - bool IsPlaying (); - bool IsMIDI () { return false; } - bool IsValid () { return m_Inited; } - -protected: - CDSong () { m_Inited = false; } - - int m_Track; - bool m_Inited; -}; - -class CDDAFile : public CDSong -{ -public: - CDDAFile (int handle, int pos, int len); -}; - -static MusInfo *currSong; -static HANDLE BufferReturnEvent; -static int nomusic = 0; -static int musicvolume; -static DWORD midivolume; -static DWORD nummididevices; -static bool nummididevicesset; -static UINT mididevice; - -CUSTOM_CVAR (Int, snd_mididevice, -1, CVAR_ARCHIVE|CVAR_GLOBALCONFIG) -{ - UINT oldmididev = mididevice; - - if (!nummididevicesset) - return; - - if ((*var >= (signed)nummididevices) || (*var < -1.0f)) - { - Printf ("ID out of range. Using MIDI mapper.\n"); - var = -1; - return; - } - else if (*var < 0) - { - mididevice = MIDI_MAPPER; - } - else - { - mididevice = *var; - } - - // If a song is playing, move it to the new device. - if (oldmididev != mididevice && currSong) - { - MusInfo *song = currSong; - I_StopSong ((long)song); - I_PlaySong ((long)song, song->m_Looping); - } -} - -void I_SetMIDIVolume (float volume) -{ - if (currSong && currSong->IsMIDI ()) - { - currSong->SetVolume (volume); - } - else - { - DWORD wooba = (DWORD)(volume * 0xffff) & 0xffff; - midivolume = (wooba << 16) | wooba; - } -} - -void MIDISong::SetVolume (float volume) -{ - DWORD wooba = (DWORD)(volume * 0xffff) & 0xffff; - midivolume = (wooba << 16) | wooba; - midiOutSetVolume ((HMIDIOUT)m_MidiStream, midivolume); -} - -void I_SetMusicVolume (int volume) -{ - if (volume) - { - // Internal state variable. - musicvolume = volume; - // Now set volume on output device. - if (currSong && !currSong->IsMIDI ()) - currSong->SetVolume ((float)volume / 64.0f); - } -} - -void MODSong::SetVolume (float volume) -{ - FMUSIC_SetMasterVolume (m_Module, (int)(volume * 256)); -} - -void StreamSong::SetVolume (float volume) -{ - m_Volume = (int)(volume * 255); - if (m_Channel) - { - FSOUND_SetVolumeAbsolute (m_Channel, m_Volume); - } -} - -CCMD (snd_listmididevices) -{ - UINT id; - MIDIOUTCAPS caps; - MMRESULT res; - - if (nummididevices) - { - Printf ("-1. MIDI Mapper\n"); - } - else - { - Printf ("No MIDI devices installed.\n"); - return; - } - - for (id = 0; id < nummididevices; id++) - { - res = midiOutGetDevCaps (id, &caps, sizeof(caps)); - if (res == MMSYSERR_NODRIVER) - strcpy (caps.szPname, ""); - else if (res == MMSYSERR_NOMEM) - strcpy (caps.szPname, ""); - else if (res != MMSYSERR_NOERROR) - continue; - - Printf ("% 2d. %s\n", id, caps.szPname); - } -} - -void I_InitMusic (void) -{ - static bool setatterm = false; - - Printf ("I_InitMusic\n"); - - nummididevices = midiOutGetNumDevs (); - nummididevicesset = true; - snd_mididevice.Callback (); - snd_musicvolume.Callback (); - - nomusic = !!Args.CheckParm("-nomusic") || !!Args.CheckParm("-nosound") || !nummididevices; - - if (!nomusic) - { - if ((BufferReturnEvent = CreateEvent (NULL, FALSE, FALSE, NULL)) == NULL) - { - Printf ("Could not create MIDI callback event.\nMIDI music will be disabled.\n"); - nomusic = true; - } - } - - if (!setatterm) - { - setatterm = true; - atterm (I_ShutdownMusic); - } -} - - -void STACK_ARGS I_ShutdownMusic(void) -{ - if (currSong) - { - S_StopMusic (true); - /* - I_UnRegisterSong ((long)currSong); - currSong = NULL; - */ - assert (currSong == NULL); - } - if (BufferReturnEvent) - { - CloseHandle (BufferReturnEvent); - BufferReturnEvent = NULL; - } -} - - -void MIDISong::MCIError (MMRESULT res, const char *descr) -{ - char errorStr[256]; - - mciGetErrorString (res, errorStr, 255); - Printf_Bold ("An error occured while %s:\n", descr); - Printf ("%s\n", errorStr); -} - -void MIDISong::UnprepareHeaders () -{ - PSTREAMBUF buffer = m_Buffers; - - while (buffer) - { - if (buffer->prepared) - { - MMRESULT res = midiOutUnprepareHeader ((HMIDIOUT)m_MidiStream, - &buffer->midiHeader, sizeof(buffer->midiHeader)); - if (res != MMSYSERR_NOERROR) - MCIError (res, "unpreparing headers"); - else - buffer->prepared = false; - } - buffer = buffer->pNext; - } -} - -bool MIDISong::PrepareHeaders () -{ - MMRESULT res; - PSTREAMBUF buffer = m_Buffers; - - while (buffer) - { - if (!buffer->prepared) - { - memset (&buffer->midiHeader, 0, sizeof(MIDIHDR)); - buffer->midiHeader.lpData = (char *)buffer->pBuffer; - buffer->midiHeader.dwBufferLength = CB_STREAMBUF; - buffer->midiHeader.dwBytesRecorded = CB_STREAMBUF - buffer->cbLeft; - res = midiOutPrepareHeader ((HMIDIOUT)m_MidiStream, - &buffer->midiHeader, sizeof(MIDIHDR)); - if (res != MMSYSERR_NOERROR) - { - MCIError (res, "preparing headers"); - UnprepareHeaders (); - return false; - } else - buffer->prepared = true; - } - buffer = buffer->pNext; - } - - return true; -} - -void MIDISong::SubmitBuffer () -{ - MMRESULT res; - - res = midiStreamOut (m_MidiStream, - &m_CurrBuffer->midiHeader, sizeof(MIDIHDR)); - - if (res != MMSYSERR_NOERROR) - MCIError (res, "sending MIDI stream"); - - m_CurrBuffer = m_CurrBuffer->pNext; - if (m_CurrBuffer == NULL && m_Looping) - m_CurrBuffer = m_Buffers; -} - -void MIDISong::AllChannelsOff () -{ - int i; - - for (i = 0; i < 16; i++) - midiOutShortMsg ((HMIDIOUT)m_MidiStream, MIDI_NOTEOFF | i | (64<<16) | (60<<8)); - Sleep (1); -} - -static void CALLBACK MidiProc (HMIDIIN hMidi, UINT uMsg, MIDISong *info, - DWORD dwParam1, DWORD dwParam2) -{ - info->MidiProc (uMsg); -} - -void MIDISong::MidiProc (UINT uMsg) -{ - if (m_CallbackStatus == cb_dead) - return; - - switch (uMsg) - { - case MOM_DONE: - if (m_CallbackStatus == cb_die) - { - SetEvent (BufferReturnEvent); - m_CallbackStatus = cb_dead; - } - else - { - if (m_CurrBuffer == m_Buffers) - { - // Stop all notes before restarting the song - // in case any are left hanging. - AllChannelsOff (); - } - else if (m_CurrBuffer == NULL) - { - SetEvent (BufferReturnEvent); - return; - } - SubmitBuffer (); - } - break; - } -} - -void I_PlaySong (long handle, int _looping) -{ - MusInfo *info = (MusInfo *)handle; - - if (!info || nomusic) - return; - - info->Stop (); - info->Play (_looping ? true : false); - - if (info->m_Status == MusInfo::STATE_Playing) - currSong = info; - else - currSong = NULL; -} - -void MIDISong::Play (bool looping) -{ - m_Status = STATE_Stopped; - m_Looping = looping; - - MMRESULT res; - - // note: midiStreamOpen changes mididevice if it's set to MIDI_MAPPER - // (interesting undocumented behavior) - if ((res = midiStreamOpen (&m_MidiStream, - &mididevice, - (DWORD)1, (DWORD)::MidiProc, - (DWORD)this, - CALLBACK_FUNCTION)) == MMSYSERR_NOERROR) - { - MIDIPROPTIMEDIV timedivProp; - - timedivProp.cbStruct = sizeof(timedivProp); - timedivProp.dwTimeDiv = midTimeDiv; - res = midiStreamProperty (m_MidiStream, (LPBYTE)&timedivProp, - MIDIPROP_SET | MIDIPROP_TIMEDIV); - if (res != MMSYSERR_NOERROR) - MCIError (res, "setting time division"); - - res = midiOutSetVolume ((HMIDIOUT)m_MidiStream, midivolume); - - // Preload all instruments into soundcard RAM (if necessary). - // On my GUS PnP, this is necessary because it will fail to - // play some instruments on some songs until the song loops - // if the instrument isn't already in memory. (Why it doesn't - // load them when they're needed is beyond me, because it's only - // some instruments it doesn't play properly the first time--and - // I don't know exactly which ones those are.) The 250 ms delay - // between note on and note off is fairly lengthy, so I try and - // get the instruments going on multiple channels to reduce the - // number of times I have to sleep. - { - int i, j; - - DPrintf ("MIDI uses instruments:\n"); - for (i = j = 0; i < 127; i++) - if (UsedPatches[i]) - { - DPrintf (" %d", i); - midiOutShortMsg ((HMIDIOUT)m_MidiStream, - MIDI_PRGMCHANGE | (i<<8) | j); - midiOutShortMsg ((HMIDIOUT)m_MidiStream, - MIDI_NOTEON | (60<<8) | (1<<16) | j); - if (++j == 10) - { - Sleep (250); - for (j = 0; j < 10; j++) - midiOutShortMsg ((HMIDIOUT)m_MidiStream, - MIDI_NOTEOFF | (60<<8) | (64<<16) | j); - j = 0; - } - } - if (j > 0) - { - Sleep (250); - for (i = 0; i < j; i++) - midiOutShortMsg ((HMIDIOUT)m_MidiStream, - MIDI_NOTEOFF | (60<<8) | (64<<16) | i); - } - - /* - DPrintf ("\nMIDI uses percussion keys:\n"); - for (i = 0; i < 127; i++) - if (UsedPatches[i+128]) { - DPrintf (" %d", i); - midiOutShortMsg ((HMIDIOUT)info->midiStream, - MIDI_NOTEON | (i<<8) | (1<<16) | 10); - Sleep (235); - midiOutShortMsg ((HMIDIOUT)info->midiStream, - MIDI_NOTEOFF | (i<<8) | (64<<16)); - } - */ - DPrintf ("\n"); - } - - if (PrepareHeaders ()) - { - m_CallbackStatus = cb_play; - m_CurrBuffer = m_Buffers; - SubmitBuffer (); - res = midiStreamRestart (m_MidiStream); - if (res == MMSYSERR_NOERROR) - { - m_Status = STATE_Playing; - } - else - { - MCIError (res, "starting playback"); - UnprepareHeaders (); - midiStreamClose (m_MidiStream); - m_MidiStream = NULL; - m_Status = STATE_Stopped; - } - } - else - { - UnprepareHeaders (); - midiStreamClose (m_MidiStream); - m_MidiStream = NULL; - m_Status = STATE_Stopped; - } - } - else - { - MCIError (res, "opening MIDI stream"); - if (*snd_mididevice != -1) - { - Printf ("Trying again with MIDI mapper\n"); - snd_mididevice = -1; - } - else - { - m_Status = STATE_Stopped; - } - } -} - -void MODSong::Play (bool looping) -{ - m_Status = STATE_Stopped; - m_Looping = looping; - - if (FMUSIC_PlaySong (m_Module)) - { - FMUSIC_SetMasterVolume (m_Module, musicvolume << 2); - m_Status = STATE_Playing; - } -} - -void StreamSong::Play (bool looping) -{ - m_Status = STATE_Stopped; - m_Looping = looping; - - m_Channel = FSOUND_Stream_Play (FSOUND_FREE, m_Stream); - if (m_Channel != -1) - { - FSOUND_SetVolumeAbsolute (m_Channel, m_Volume); - FSOUND_SetPan (m_Channel, FSOUND_STEREOPAN); - m_Status = STATE_Playing; - m_LastPos = 0; - } -} - -void CDSong::Play (bool looping) -{ - m_Status = STATE_Stopped; - m_Looping = looping; - if (m_Track != 0 ? CD_Play (m_Track, looping) : CD_PlayCD (looping)) - { - m_Status = STATE_Playing; - } -} - -void I_PauseSong (long handle) -{ - MusInfo *info = (MusInfo *)handle; - - if (info) - info->Pause (); -} - -void MIDISong::Pause () -{ - if (m_Status == STATE_Playing && - m_MidiStream && - midiStreamPause (m_MidiStream) == MMSYSERR_NOERROR) - { - m_Status = STATE_Paused; - } -} - -void MODSong::Pause () -{ - if (m_Status == STATE_Playing) - { - if (FMUSIC_SetPaused (m_Module, TRUE)) - m_Status = STATE_Paused; - } -} - -void StreamSong::Pause () -{ - if (m_Status == STATE_Playing) - { - if (FSOUND_Stream_SetPaused (m_Stream, TRUE)) - m_Status = STATE_Paused; - } -} - -void CDSong::Pause () -{ - if (m_Status == STATE_Playing) - { - CD_Pause (); - m_Status = STATE_Paused; - } -} - -void I_ResumeSong (long handle) -{ - MusInfo *info = (MusInfo *)handle; - - if (info) - info->Resume (); -} - -void MIDISong::Resume () -{ - if (m_Status == STATE_Paused && - m_MidiStream && - midiStreamRestart (m_MidiStream) == MMSYSERR_NOERROR) - { - m_Status = STATE_Playing; - } -} - -void MODSong::Resume () -{ - if (m_Status == STATE_Paused) - { - if (FMUSIC_SetPaused (m_Module, FALSE)) - m_Status = STATE_Playing; - } -} - -void CDSong::Resume () -{ - if (m_Status == STATE_Paused) - { - if (CD_Resume ()) - m_Status = STATE_Playing; - } -} - -void StreamSong::Resume () -{ - if (m_Status == STATE_Paused) - { - if (FSOUND_Stream_SetPaused (m_Stream, FALSE)) - m_Status = STATE_Playing; - } -} - -void I_StopSong (long handle) -{ - MusInfo *info = (MusInfo *)handle; - - if (info) - info->Stop (); - - if (info == currSong) - currSong = NULL; -} - -void MIDISong::Stop () -{ - if (m_Status != STATE_Stopped && m_MidiStream) - { - if (m_CallbackStatus != cb_dead) - m_CallbackStatus = cb_die; - midiStreamStop (m_MidiStream); - WaitForSingleObject (BufferReturnEvent, 5000); - midiOutReset ((HMIDIOUT)m_MidiStream); - UnprepareHeaders (); - midiStreamClose (m_MidiStream); - m_MidiStream = NULL; - } - m_Status = STATE_Stopped; -} - -void MODSong::Stop () -{ - if (m_Status != STATE_Stopped && m_Module) - { - FMUSIC_StopSong (m_Module); - } - m_Status = STATE_Stopped; -} - -void StreamSong::Stop () -{ - if (m_Status != STATE_Stopped && m_Stream) - { - FSOUND_Stream_Stop (m_Stream); - m_Channel = -1; - } - m_Status = STATE_Stopped; -} - -void CDSong::Stop () -{ - if (m_Status != STATE_Stopped) - { - m_Status = STATE_Stopped; - CD_Stop (); - } -} - -void I_UnRegisterSong (long handle) -{ - MusInfo *info = (MusInfo *)handle; - - if (info) - { - delete info; - } -} - -MIDISong::~MIDISong () -{ - Stop (); - if (m_IsMUS) - mus2strmCleanup (); - else - mid2strmCleanup (); - m_Buffers = NULL; -} - -MODSong::~MODSong () -{ - Stop (); - FMUSIC_FreeSong (m_Module); - m_Module = NULL; -} - -StreamSong::~StreamSong () -{ - Stop (); - FSOUND_Stream_Close (m_Stream); - m_Stream = NULL; -} - -CDSong::~CDSong () -{ - Stop (); - m_Inited = false; -} - -long I_RegisterSong (int handle, int pos, int len) -{ - MusInfo *info = NULL; - DWORD id; - - if (nomusic) - { - return 0; - } - - lseek (handle, pos, SEEK_SET); - read (handle, &id, 4); - - if (id == (('M')|(('U')<<8)|(('S')<<16)|((0x1a)<<24))) - { - // This is a mus file - info = new MUSSong (handle, pos, len); - } - else if (id == (('M')|(('T')<<8)|(('h')<<16)|(('d')<<24))) - { - // This is a midi file - info = new MIDISong (handle, pos, len); - } - else if (id == (('R')|(('I')<<8)|(('F')<<16)|(('F')<<24))) - { - DWORD subid = 0; - lseek (handle, pos+8, SEEK_SET); - read (handle, &subid, 4); - if (subid == (('C')|(('D')<<8)|(('D')<<16)|(('A')<<24))) - { - // This is a CDDA file - info = new CDDAFile (handle, pos, len); - } - } - else if (!_nosound) // no FSOUND => no modules/mp3s - { - // First try loading it as MOD, then as MP3 - info = new MODSong (handle, pos, len); - if (!info->IsValid ()) - { - delete info; - info = new StreamSong (handle, pos, len); - } - } - - if (info && !info->IsValid ()) - { - delete info; - info = NULL; - } - - return info ? (long)info : 0; -} - -long I_RegisterCDSong (int track, int id) -{ - MusInfo *info = new CDSong (track, id); - - if (info && !info->IsValid ()) - { - delete info; - info = NULL; - } - - return info ? (long)info : 0; -} - -MIDISong::MIDISong () -{ - m_Buffers = NULL; - m_IsMUS = false; -} - -MIDISong::MIDISong (int handle, int pos, int len) -{ - m_Buffers = NULL; - m_IsMUS = false; - if (nummididevices > 0 && lseek (handle, pos, SEEK_SET) != -1) - { - byte *data = new byte[len]; - if (read (handle, data, len) == len) - { - m_Buffers = mid2strmConvert ((LPBYTE)data, len); - } - delete[] data; - } -} - -MUSSong::MUSSong (int handle, int pos, int len) : MIDISong () -{ - m_Buffers = NULL; - m_IsMUS = true; - if (nummididevices > 0 && lseek (handle, pos, SEEK_SET) != -1) - { - byte *data = new byte[len]; - if (read (handle, data, len) == len) - { - m_Buffers = mus2strmConvert ((LPBYTE)data, len); - } - delete[] data; - } -} - -MODSong::MODSong (int handle, int pos, int len) -{ - m_Module = FMUSIC_LoadSong ((char *)new FileHandle (handle, pos, len)); -} - -StreamSong::StreamSong (int handle, int pos, int len) -{ - m_Channel = -1; - m_Stream = FSOUND_Stream_OpenFile ((char *)new FileHandle (handle, pos, len), - FSOUND_LOOP_NORMAL|FSOUND_NORMAL, 0); - if (m_Stream != NULL) - { - m_Length = FSOUND_Stream_GetLength (m_Stream); - } -} - -CDSong::CDSong (int track, int id) -{ - bool success; - - m_Inited = false; - - if (id != 0) - { - success = CD_InitID (id); - } - else - { - success = CD_Init (); - } - - if (success && track == 0 || CD_CheckTrack (track)) - { - m_Inited = true; - m_Track = track; - } -} - -CDDAFile::CDDAFile (int handle, int pos, int len) - : CDSong () -{ - DWORD chunk; - WORD track; - DWORD discid; - int cursor = 12; - - // I_RegisterSong already identified this as a CDDA file, so we - // just need to check the contents we're interested in. - - while (cursor < len - 8) - { - if (lseek (handle, pos+cursor, SEEK_SET) == -1) - return; - if (read (handle, &chunk, 4) != 4) - return; - if (chunk != (('f')|(('m')<<8)|(('t')<<16)|((' ')<<24))) - { - if (read (handle, &chunk, 4) != 4) - return; - cursor += LONG(chunk) + 8; - } - else - { - if (lseek (handle, pos+cursor+10, SEEK_SET) != -1) - { - if (read (handle, &track, 2) == 2 && - read (handle, &discid, 4) == 4) - { - track = SHORT(track); - discid = LONG(discid); - - if (CD_InitID (discid) && CD_CheckTrack (track)) - { - m_Inited = true; - m_Track = track; - } - } - } - return; - } - } -} - -// Is the song playing? -bool I_QrySongPlaying (long handle) -{ - MusInfo *info = (MusInfo *)handle; - - return info ? info->IsPlaying () : false; -} - -bool MIDISong::IsPlaying () -{ - return m_Looping ? true : m_Status != STATE_Stopped; -} - -bool MODSong::IsPlaying () -{ - if (m_Status != STATE_Stopped && FMUSIC_IsPlaying (m_Module)) - { - if (!m_Looping && FMUSIC_IsFinished (m_Module)) - { - Stop(); - return false; - } - return true; - } - return false; -} - -bool StreamSong::IsPlaying () -{ - if (m_Channel != -1) - { - if (m_Looping) - return true; - - int pos = FSOUND_Stream_GetPosition (m_Stream); - - if (pos < m_LastPos) - { - Stop (); - return false; - } - - m_LastPos = pos; - return true; - } - return false; -} - -bool CDSong::IsPlaying () -{ - if (m_Status == STATE_Playing) - { - if (CD_GetMode () != CDMode_Play) - { - Stop (); - } - } - return m_Status != STATE_Stopped; -} - -// Change to a different part of the song -bool I_SetSongPosition (long handle, int order) -{ - MusInfo *info = (MusInfo *)handle; - return info ? info->SetPosition (order) : false; -} - -bool MODSong::SetPosition (int order) -{ - return !!FMUSIC_SetOrder (m_Module, order); -} diff --git a/code/win32/mus2strm.h b/code/win32/mus2strm.h deleted file mode 100644 index 36cb37fe28..0000000000 --- a/code/win32/mus2strm.h +++ /dev/null @@ -1,45 +0,0 @@ -#ifndef __MUS2STRM_H__ -#define __MUS2STRM_H__ - -#include "mid2strm.h" - -#define MUS_RELEASE 0 -#define MUS_PLAY 1 -#define MUS_PITCHBEND 2 -#define MUS_SYSEVENT 3 -#define MUS_CTRLCHANGE 4 -#define MUS_UNKNOWN1 5 -#define MUS_END 6 -#define MUS_UNKNOWN2 7 - -#define MUSMAGIC "MUS\032" - -typedef unsigned short int2; - -typedef struct -{ - char ID[4]; /* identifier "MUS" 0x1A */ - int2 ScoreLength; - int2 ScoreStart; - int2 channels; /* count of primary channels */ - int2 SecChannels; /* count of secondary channels (?) */ - int2 InstrCnt; -} MUSheader; - -struct Track -{ - unsigned long current; - char vel; - long DeltaTime; - unsigned char LastEvent; - char *data; /* Primary data */ -}; - -extern OUTSTREAMSTATE ots; - - -PSTREAMBUF mus2strmConvert (BYTE *inFile, DWORD inSize); -void mus2strmCleanup (void); - - -#endif //__MUS2STRM_H__ \ No newline at end of file diff --git a/code/docs/BUILDLIC.TXT b/docs/BUILDLIC.TXT similarity index 100% rename from code/docs/BUILDLIC.TXT rename to docs/BUILDLIC.TXT diff --git a/code/docs/README.Carmack b/docs/README.Carmack similarity index 100% rename from code/docs/README.Carmack rename to docs/README.Carmack diff --git a/code/docs/README.asm b/docs/README.asm similarity index 100% rename from code/docs/README.asm rename to docs/README.asm diff --git a/code/docs/README.gl b/docs/README.gl similarity index 100% rename from code/docs/README.gl rename to docs/README.gl diff --git a/code/docs/classes.txt b/docs/classes.txt similarity index 98% rename from code/docs/classes.txt rename to docs/classes.txt index 5d12212956..cf239a7a93 100644 --- a/code/docs/classes.txt +++ b/docs/classes.txt @@ -1,8 +1,3 @@ -This file is sorely outdated in regards to DObject usage. You can still use -it as a baseline, but see the source for actual implementation details, since -many of them have changed. - - ZDoom 1.19 offers a partial conversion of the Doom code to C++. As such, some functions and classes have been encapsulated in classes. This document tries to give an overview of those classes and how to use them. diff --git a/docs/colors.txt b/docs/colors.txt new file mode 100644 index 0000000000..4e27901a71 --- /dev/null +++ b/docs/colors.txt @@ -0,0 +1,756 @@ +! $XConsortium: rgb.txt,v 10.41 94/02/20 18:39:36 rws Exp $ + +255 250 250 snow +248 248 255 ghost white +248 248 255 GhostWhite +245 245 245 white smoke +245 245 245 WhiteSmoke +220 220 220 gainsboro +255 250 240 floral white +255 250 240 FloralWhite +253 245 230 old lace +253 245 230 OldLace +250 240 230 linen +250 235 215 antique white +250 235 215 AntiqueWhite +255 239 213 papaya whip +255 239 213 PapayaWhip +255 235 205 blanched almond +255 235 205 BlanchedAlmond +255 228 196 bisque +255 218 185 peach puff +255 218 185 PeachPuff +255 222 173 navajo white +255 222 173 NavajoWhite +255 228 181 moccasin +255 248 220 cornsilk +255 255 240 ivory +255 250 205 lemon chiffon +255 250 205 LemonChiffon +255 245 238 seashell +240 255 240 honeydew +245 255 250 mint cream +245 255 250 MintCream +240 255 255 azure +240 248 255 alice blue +240 248 255 AliceBlue +230 230 250 lavender +255 240 245 lavender blush +255 240 245 LavenderBlush +255 228 225 misty rose +255 228 225 MistyRose +255 255 255 white + 0 0 0 black + 47 79 79 dark slate gray + 47 79 79 DarkSlateGray + 47 79 79 dark slate grey + 47 79 79 DarkSlateGrey +105 105 105 dim gray +105 105 105 DimGray +105 105 105 dim grey +105 105 105 DimGrey +112 128 144 slate gray +112 128 144 SlateGray +112 128 144 slate grey +112 128 144 SlateGrey +119 136 153 light slate gray +119 136 153 LightSlateGray +119 136 153 light slate grey +119 136 153 LightSlateGrey +190 190 190 gray +190 190 190 grey +211 211 211 light grey +211 211 211 LightGrey +211 211 211 light gray +211 211 211 LightGray + 25 25 112 midnight blue + 25 25 112 MidnightBlue + 0 0 128 navy + 0 0 128 navy blue + 0 0 128 NavyBlue +100 149 237 cornflower blue +100 149 237 CornflowerBlue + 72 61 139 dark slate blue + 72 61 139 DarkSlateBlue +106 90 205 slate blue +106 90 205 SlateBlue +123 104 238 medium slate blue +123 104 238 MediumSlateBlue +132 112 255 light slate blue +132 112 255 LightSlateBlue + 0 0 205 medium blue + 0 0 205 MediumBlue + 65 105 225 royal blue + 65 105 225 RoyalBlue + 0 0 255 blue + 30 144 255 dodger blue + 30 144 255 DodgerBlue + 0 191 255 deep sky blue + 0 191 255 DeepSkyBlue +135 206 235 sky blue +135 206 235 SkyBlue +135 206 250 light sky blue +135 206 250 LightSkyBlue + 70 130 180 steel blue + 70 130 180 SteelBlue +176 196 222 light steel blue +176 196 222 LightSteelBlue +173 216 230 light blue +173 216 230 LightBlue +176 224 230 powder blue +176 224 230 PowderBlue +175 238 238 pale turquoise +175 238 238 PaleTurquoise + 0 206 209 dark turquoise + 0 206 209 DarkTurquoise + 72 209 204 medium turquoise + 72 209 204 MediumTurquoise + 64 224 208 turquoise + 0 255 255 cyan +224 255 255 light cyan +224 255 255 LightCyan + 95 158 160 cadet blue + 95 158 160 CadetBlue +102 205 170 medium aquamarine +102 205 170 MediumAquamarine +127 255 212 aquamarine + 0 100 0 dark green + 0 100 0 DarkGreen + 85 107 47 dark olive green + 85 107 47 DarkOliveGreen +143 188 143 dark sea green +143 188 143 DarkSeaGreen + 46 139 87 sea green + 46 139 87 SeaGreen + 60 179 113 medium sea green + 60 179 113 MediumSeaGreen + 32 178 170 light sea green + 32 178 170 LightSeaGreen +152 251 152 pale green +152 251 152 PaleGreen + 0 255 127 spring green + 0 255 127 SpringGreen +124 252 0 lawn green +124 252 0 LawnGreen + 0 255 0 green +127 255 0 chartreuse + 0 250 154 medium spring green + 0 250 154 MediumSpringGreen +173 255 47 green yellow +173 255 47 GreenYellow + 50 205 50 lime green + 50 205 50 LimeGreen +154 205 50 yellow green +154 205 50 YellowGreen + 34 139 34 forest green + 34 139 34 ForestGreen +107 142 35 olive drab +107 142 35 OliveDrab +189 183 107 dark khaki +189 183 107 DarkKhaki +240 230 140 khaki +238 232 170 pale goldenrod +238 232 170 PaleGoldenrod +250 250 210 light goldenrod yellow +250 250 210 LightGoldenrodYellow +255 255 224 light yellow +255 255 224 LightYellow +255 255 0 yellow +255 215 0 gold +238 221 130 light goldenrod +238 221 130 LightGoldenrod +218 165 32 goldenrod +184 134 11 dark goldenrod +184 134 11 DarkGoldenrod +188 143 143 rosy brown +188 143 143 RosyBrown +205 92 92 indian red +205 92 92 IndianRed +139 69 19 saddle brown +139 69 19 SaddleBrown +160 82 45 sienna +205 133 63 peru +222 184 135 burlywood +245 245 220 beige +245 222 179 wheat +244 164 96 sandy brown +244 164 96 SandyBrown +210 180 140 tan +210 105 30 chocolate +178 34 34 firebrick +165 42 42 brown +233 150 122 dark salmon +233 150 122 DarkSalmon +250 128 114 salmon +255 160 122 light salmon +255 160 122 LightSalmon +255 165 0 orange +255 140 0 dark orange +255 140 0 DarkOrange +255 127 80 coral +240 128 128 light coral +240 128 128 LightCoral +255 99 71 tomato +255 69 0 orange red +255 69 0 OrangeRed +255 0 0 red +255 105 180 hot pink +255 105 180 HotPink +255 20 147 deep pink +255 20 147 DeepPink +255 192 203 pink +255 182 193 light pink +255 182 193 LightPink +219 112 147 pale violet red +219 112 147 PaleVioletRed +176 48 96 maroon +199 21 133 medium violet red +199 21 133 MediumVioletRed +208 32 144 violet red +208 32 144 VioletRed +255 0 255 magenta +238 130 238 violet +221 160 221 plum +218 112 214 orchid +186 85 211 medium orchid +186 85 211 MediumOrchid +153 50 204 dark orchid +153 50 204 DarkOrchid +148 0 211 dark violet +148 0 211 DarkViolet +138 43 226 blue violet +138 43 226 BlueViolet +160 32 240 purple +147 112 219 medium purple +147 112 219 MediumPurple +216 191 216 thistle +255 250 250 snow1 +238 233 233 snow2 +205 201 201 snow3 +139 137 137 snow4 +255 245 238 seashell1 +238 229 222 seashell2 +205 197 191 seashell3 +139 134 130 seashell4 +255 239 219 AntiqueWhite1 +238 223 204 AntiqueWhite2 +205 192 176 AntiqueWhite3 +139 131 120 AntiqueWhite4 +255 228 196 bisque1 +238 213 183 bisque2 +205 183 158 bisque3 +139 125 107 bisque4 +255 218 185 PeachPuff1 +238 203 173 PeachPuff2 +205 175 149 PeachPuff3 +139 119 101 PeachPuff4 +255 222 173 NavajoWhite1 +238 207 161 NavajoWhite2 +205 179 139 NavajoWhite3 +139 121 94 NavajoWhite4 +255 250 205 LemonChiffon1 +238 233 191 LemonChiffon2 +205 201 165 LemonChiffon3 +139 137 112 LemonChiffon4 +255 248 220 cornsilk1 +238 232 205 cornsilk2 +205 200 177 cornsilk3 +139 136 120 cornsilk4 +255 255 240 ivory1 +238 238 224 ivory2 +205 205 193 ivory3 +139 139 131 ivory4 +240 255 240 honeydew1 +224 238 224 honeydew2 +193 205 193 honeydew3 +131 139 131 honeydew4 +255 240 245 LavenderBlush1 +238 224 229 LavenderBlush2 +205 193 197 LavenderBlush3 +139 131 134 LavenderBlush4 +255 228 225 MistyRose1 +238 213 210 MistyRose2 +205 183 181 MistyRose3 +139 125 123 MistyRose4 +240 255 255 azure1 +224 238 238 azure2 +193 205 205 azure3 +131 139 139 azure4 +131 111 255 SlateBlue1 +122 103 238 SlateBlue2 +105 89 205 SlateBlue3 + 71 60 139 SlateBlue4 + 72 118 255 RoyalBlue1 + 67 110 238 RoyalBlue2 + 58 95 205 RoyalBlue3 + 39 64 139 RoyalBlue4 + 0 0 255 blue1 + 0 0 238 blue2 + 0 0 205 blue3 + 0 0 139 blue4 + 30 144 255 DodgerBlue1 + 28 134 238 DodgerBlue2 + 24 116 205 DodgerBlue3 + 16 78 139 DodgerBlue4 + 99 184 255 SteelBlue1 + 92 172 238 SteelBlue2 + 79 148 205 SteelBlue3 + 54 100 139 SteelBlue4 + 0 191 255 DeepSkyBlue1 + 0 178 238 DeepSkyBlue2 + 0 154 205 DeepSkyBlue3 + 0 104 139 DeepSkyBlue4 +135 206 255 SkyBlue1 +126 192 238 SkyBlue2 +108 166 205 SkyBlue3 + 74 112 139 SkyBlue4 +176 226 255 LightSkyBlue1 +164 211 238 LightSkyBlue2 +141 182 205 LightSkyBlue3 + 96 123 139 LightSkyBlue4 +198 226 255 SlateGray1 +185 211 238 SlateGray2 +159 182 205 SlateGray3 +108 123 139 SlateGray4 +202 225 255 LightSteelBlue1 +188 210 238 LightSteelBlue2 +162 181 205 LightSteelBlue3 +110 123 139 LightSteelBlue4 +191 239 255 LightBlue1 +178 223 238 LightBlue2 +154 192 205 LightBlue3 +104 131 139 LightBlue4 +224 255 255 LightCyan1 +209 238 238 LightCyan2 +180 205 205 LightCyan3 +122 139 139 LightCyan4 +187 255 255 PaleTurquoise1 +174 238 238 PaleTurquoise2 +150 205 205 PaleTurquoise3 +102 139 139 PaleTurquoise4 +152 245 255 CadetBlue1 +142 229 238 CadetBlue2 +122 197 205 CadetBlue3 + 83 134 139 CadetBlue4 + 0 245 255 turquoise1 + 0 229 238 turquoise2 + 0 197 205 turquoise3 + 0 134 139 turquoise4 + 0 255 255 cyan1 + 0 238 238 cyan2 + 0 205 205 cyan3 + 0 139 139 cyan4 +151 255 255 DarkSlateGray1 +141 238 238 DarkSlateGray2 +121 205 205 DarkSlateGray3 + 82 139 139 DarkSlateGray4 +127 255 212 aquamarine1 +118 238 198 aquamarine2 +102 205 170 aquamarine3 + 69 139 116 aquamarine4 +193 255 193 DarkSeaGreen1 +180 238 180 DarkSeaGreen2 +155 205 155 DarkSeaGreen3 +105 139 105 DarkSeaGreen4 + 84 255 159 SeaGreen1 + 78 238 148 SeaGreen2 + 67 205 128 SeaGreen3 + 46 139 87 SeaGreen4 +154 255 154 PaleGreen1 +144 238 144 PaleGreen2 +124 205 124 PaleGreen3 + 84 139 84 PaleGreen4 + 0 255 127 SpringGreen1 + 0 238 118 SpringGreen2 + 0 205 102 SpringGreen3 + 0 139 69 SpringGreen4 + 0 255 0 green1 + 0 238 0 green2 + 0 205 0 green3 + 0 139 0 green4 +127 255 0 chartreuse1 +118 238 0 chartreuse2 +102 205 0 chartreuse3 + 69 139 0 chartreuse4 +192 255 62 OliveDrab1 +179 238 58 OliveDrab2 +154 205 50 OliveDrab3 +105 139 34 OliveDrab4 +202 255 112 DarkOliveGreen1 +188 238 104 DarkOliveGreen2 +162 205 90 DarkOliveGreen3 +110 139 61 DarkOliveGreen4 +255 246 143 khaki1 +238 230 133 khaki2 +205 198 115 khaki3 +139 134 78 khaki4 +255 236 139 LightGoldenrod1 +238 220 130 LightGoldenrod2 +205 190 112 LightGoldenrod3 +139 129 76 LightGoldenrod4 +255 255 224 LightYellow1 +238 238 209 LightYellow2 +205 205 180 LightYellow3 +139 139 122 LightYellow4 +255 255 0 yellow1 +238 238 0 yellow2 +205 205 0 yellow3 +139 139 0 yellow4 +255 215 0 gold1 +238 201 0 gold2 +205 173 0 gold3 +139 117 0 gold4 +255 193 37 goldenrod1 +238 180 34 goldenrod2 +205 155 29 goldenrod3 +139 105 20 goldenrod4 +255 185 15 DarkGoldenrod1 +238 173 14 DarkGoldenrod2 +205 149 12 DarkGoldenrod3 +139 101 8 DarkGoldenrod4 +255 193 193 RosyBrown1 +238 180 180 RosyBrown2 +205 155 155 RosyBrown3 +139 105 105 RosyBrown4 +255 106 106 IndianRed1 +238 99 99 IndianRed2 +205 85 85 IndianRed3 +139 58 58 IndianRed4 +255 130 71 sienna1 +238 121 66 sienna2 +205 104 57 sienna3 +139 71 38 sienna4 +255 211 155 burlywood1 +238 197 145 burlywood2 +205 170 125 burlywood3 +139 115 85 burlywood4 +255 231 186 wheat1 +238 216 174 wheat2 +205 186 150 wheat3 +139 126 102 wheat4 +255 165 79 tan1 +238 154 73 tan2 +205 133 63 tan3 +139 90 43 tan4 +255 127 36 chocolate1 +238 118 33 chocolate2 +205 102 29 chocolate3 +139 69 19 chocolate4 +255 48 48 firebrick1 +238 44 44 firebrick2 +205 38 38 firebrick3 +139 26 26 firebrick4 +255 64 64 brown1 +238 59 59 brown2 +205 51 51 brown3 +139 35 35 brown4 +255 140 105 salmon1 +238 130 98 salmon2 +205 112 84 salmon3 +139 76 57 salmon4 +255 160 122 LightSalmon1 +238 149 114 LightSalmon2 +205 129 98 LightSalmon3 +139 87 66 LightSalmon4 +255 165 0 orange1 +238 154 0 orange2 +205 133 0 orange3 +139 90 0 orange4 +255 127 0 DarkOrange1 +238 118 0 DarkOrange2 +205 102 0 DarkOrange3 +139 69 0 DarkOrange4 +255 114 86 coral1 +238 106 80 coral2 +205 91 69 coral3 +139 62 47 coral4 +255 99 71 tomato1 +238 92 66 tomato2 +205 79 57 tomato3 +139 54 38 tomato4 +255 69 0 OrangeRed1 +238 64 0 OrangeRed2 +205 55 0 OrangeRed3 +139 37 0 OrangeRed4 +255 0 0 red1 +238 0 0 red2 +205 0 0 red3 +139 0 0 red4 +255 20 147 DeepPink1 +238 18 137 DeepPink2 +205 16 118 DeepPink3 +139 10 80 DeepPink4 +255 110 180 HotPink1 +238 106 167 HotPink2 +205 96 144 HotPink3 +139 58 98 HotPink4 +255 181 197 pink1 +238 169 184 pink2 +205 145 158 pink3 +139 99 108 pink4 +255 174 185 LightPink1 +238 162 173 LightPink2 +205 140 149 LightPink3 +139 95 101 LightPink4 +255 130 171 PaleVioletRed1 +238 121 159 PaleVioletRed2 +205 104 137 PaleVioletRed3 +139 71 93 PaleVioletRed4 +255 52 179 maroon1 +238 48 167 maroon2 +205 41 144 maroon3 +139 28 98 maroon4 +255 62 150 VioletRed1 +238 58 140 VioletRed2 +205 50 120 VioletRed3 +139 34 82 VioletRed4 +255 0 255 magenta1 +238 0 238 magenta2 +205 0 205 magenta3 +139 0 139 magenta4 +255 131 250 orchid1 +238 122 233 orchid2 +205 105 201 orchid3 +139 71 137 orchid4 +255 187 255 plum1 +238 174 238 plum2 +205 150 205 plum3 +139 102 139 plum4 +224 102 255 MediumOrchid1 +209 95 238 MediumOrchid2 +180 82 205 MediumOrchid3 +122 55 139 MediumOrchid4 +191 62 255 DarkOrchid1 +178 58 238 DarkOrchid2 +154 50 205 DarkOrchid3 +104 34 139 DarkOrchid4 +155 48 255 purple1 +145 44 238 purple2 +125 38 205 purple3 + 85 26 139 purple4 +171 130 255 MediumPurple1 +159 121 238 MediumPurple2 +137 104 205 MediumPurple3 + 93 71 139 MediumPurple4 +255 225 255 thistle1 +238 210 238 thistle2 +205 181 205 thistle3 +139 123 139 thistle4 + 0 0 0 gray0 + 0 0 0 grey0 + 3 3 3 gray1 + 3 3 3 grey1 + 5 5 5 gray2 + 5 5 5 grey2 + 8 8 8 gray3 + 8 8 8 grey3 + 10 10 10 gray4 + 10 10 10 grey4 + 13 13 13 gray5 + 13 13 13 grey5 + 15 15 15 gray6 + 15 15 15 grey6 + 18 18 18 gray7 + 18 18 18 grey7 + 20 20 20 gray8 + 20 20 20 grey8 + 23 23 23 gray9 + 23 23 23 grey9 + 26 26 26 gray10 + 26 26 26 grey10 + 28 28 28 gray11 + 28 28 28 grey11 + 31 31 31 gray12 + 31 31 31 grey12 + 33 33 33 gray13 + 33 33 33 grey13 + 36 36 36 gray14 + 36 36 36 grey14 + 38 38 38 gray15 + 38 38 38 grey15 + 41 41 41 gray16 + 41 41 41 grey16 + 43 43 43 gray17 + 43 43 43 grey17 + 46 46 46 gray18 + 46 46 46 grey18 + 48 48 48 gray19 + 48 48 48 grey19 + 51 51 51 gray20 + 51 51 51 grey20 + 54 54 54 gray21 + 54 54 54 grey21 + 56 56 56 gray22 + 56 56 56 grey22 + 59 59 59 gray23 + 59 59 59 grey23 + 61 61 61 gray24 + 61 61 61 grey24 + 64 64 64 gray25 + 64 64 64 grey25 + 66 66 66 gray26 + 66 66 66 grey26 + 69 69 69 gray27 + 69 69 69 grey27 + 71 71 71 gray28 + 71 71 71 grey28 + 74 74 74 gray29 + 74 74 74 grey29 + 77 77 77 gray30 + 77 77 77 grey30 + 79 79 79 gray31 + 79 79 79 grey31 + 82 82 82 gray32 + 82 82 82 grey32 + 84 84 84 gray33 + 84 84 84 grey33 + 87 87 87 gray34 + 87 87 87 grey34 + 89 89 89 gray35 + 89 89 89 grey35 + 92 92 92 gray36 + 92 92 92 grey36 + 94 94 94 gray37 + 94 94 94 grey37 + 97 97 97 gray38 + 97 97 97 grey38 + 99 99 99 gray39 + 99 99 99 grey39 +102 102 102 gray40 +102 102 102 grey40 +105 105 105 gray41 +105 105 105 grey41 +107 107 107 gray42 +107 107 107 grey42 +110 110 110 gray43 +110 110 110 grey43 +112 112 112 gray44 +112 112 112 grey44 +115 115 115 gray45 +115 115 115 grey45 +117 117 117 gray46 +117 117 117 grey46 +120 120 120 gray47 +120 120 120 grey47 +122 122 122 gray48 +122 122 122 grey48 +125 125 125 gray49 +125 125 125 grey49 +127 127 127 gray50 +127 127 127 grey50 +130 130 130 gray51 +130 130 130 grey51 +133 133 133 gray52 +133 133 133 grey52 +135 135 135 gray53 +135 135 135 grey53 +138 138 138 gray54 +138 138 138 grey54 +140 140 140 gray55 +140 140 140 grey55 +143 143 143 gray56 +143 143 143 grey56 +145 145 145 gray57 +145 145 145 grey57 +148 148 148 gray58 +148 148 148 grey58 +150 150 150 gray59 +150 150 150 grey59 +153 153 153 gray60 +153 153 153 grey60 +156 156 156 gray61 +156 156 156 grey61 +158 158 158 gray62 +158 158 158 grey62 +161 161 161 gray63 +161 161 161 grey63 +163 163 163 gray64 +163 163 163 grey64 +166 166 166 gray65 +166 166 166 grey65 +168 168 168 gray66 +168 168 168 grey66 +171 171 171 gray67 +171 171 171 grey67 +173 173 173 gray68 +173 173 173 grey68 +176 176 176 gray69 +176 176 176 grey69 +179 179 179 gray70 +179 179 179 grey70 +181 181 181 gray71 +181 181 181 grey71 +184 184 184 gray72 +184 184 184 grey72 +186 186 186 gray73 +186 186 186 grey73 +189 189 189 gray74 +189 189 189 grey74 +191 191 191 gray75 +191 191 191 grey75 +194 194 194 gray76 +194 194 194 grey76 +196 196 196 gray77 +196 196 196 grey77 +199 199 199 gray78 +199 199 199 grey78 +201 201 201 gray79 +201 201 201 grey79 +204 204 204 gray80 +204 204 204 grey80 +207 207 207 gray81 +207 207 207 grey81 +209 209 209 gray82 +209 209 209 grey82 +212 212 212 gray83 +212 212 212 grey83 +214 214 214 gray84 +214 214 214 grey84 +217 217 217 gray85 +217 217 217 grey85 +219 219 219 gray86 +219 219 219 grey86 +222 222 222 gray87 +222 222 222 grey87 +224 224 224 gray88 +224 224 224 grey88 +227 227 227 gray89 +227 227 227 grey89 +229 229 229 gray90 +229 229 229 grey90 +232 232 232 gray91 +232 232 232 grey91 +235 235 235 gray92 +235 235 235 grey92 +237 237 237 gray93 +237 237 237 grey93 +240 240 240 gray94 +240 240 240 grey94 +242 242 242 gray95 +242 242 242 grey95 +245 245 245 gray96 +245 245 245 grey96 +247 247 247 gray97 +247 247 247 grey97 +250 250 250 gray98 +250 250 250 grey98 +252 252 252 gray99 +252 252 252 grey99 +255 255 255 gray100 +255 255 255 grey100 +169 169 169 dark grey +169 169 169 DarkGrey +169 169 169 dark gray +169 169 169 DarkGray +0 0 139 dark blue +0 0 139 DarkBlue +0 139 139 dark cyan +0 139 139 DarkCyan +139 0 139 dark magenta +139 0 139 DarkMagenta +139 0 0 dark red +139 0 0 DarkRed +144 238 144 light green +144 238 144 LightGreen + + diff --git a/docs/commands.txt b/docs/commands.txt new file mode 100644 index 0000000000..4dfd483f33 --- /dev/null +++ b/docs/commands.txt @@ -0,0 +1,1742 @@ +This document lists all commands and cvars supported by the current version +of ZDoom (1.22) and a short description of each. There are a total of 130 +commands and 141 cvars. +=========================================================================== + +There are five types of cvars: + +boolean: This is a number that can be either "0" or "1". "0" indicates no/ + false, and "1" indicates yes/true. + + color: This is a series of three hexadecimal numbers representing the + amounts of red, green, and blue (in that order) in a color. For + example, pure redwould be represented as "ffff 0000 0000". The + setcolor command can be used to set one of these cvars using a + color name instead of numbers. (See the description of the + setcolor command below.) + + number: This is an ordinary number. + + integer: This is an ordinary that doesn't take fractional values. + + string: This is a series of text characters enclosed in quotes. + + +Some commands also take parameters. Any parameters that are required are +enclosed in < >, and those that are optional are enclosed in [ ]. + + +ACTION COMMANDS +=============== +NOTE: As in Quake, all action commands come in pairs. When prefixed by a +'+', they activate the corresponding action, and when prefixed by a '-', +they deactivate that action. + + ++attack, -attack + While active, causes the player to fire his active weapon. + ++back, -back + While active, causes the player to move backward. +See also: +forward + ++forward, -forward + While active, causes the player to move forward. +See also: +back + ++jump, -jump + Causes the player to jump. When underwater, the player will swim upward + instead. +See also: +moveup + ++klook, -klook + While active, causes +forward and +back to act like +lookup and +lookdown + instead. +See also: +mlook, +lookup, +lookdown, +forward, +back + ++left, -left + While active, normally causes the player to turn to the left. However, as + long as +strafe is active, this will cause the player to move to the left + instead. +See also: +right, +strafe, +moveleft + ++lookdown, -lookdown + While active, causes the player to look down. +See also: +lookup, +klook + ++lookup, -lookup + While active, causes the player to look up. +See also: +lookdown, +klook + ++mlook, -mlook + While active, causes movement along the mouse's vertical axis to tilt the + player's view up or down instead of moving the player forward or backward. +See also: +klook, freelook, invertmouse, lookspring + ++movedown, -movedown + Moves the player down if swimming or flying. +See also: +moveup + ++moveleft, -moveleft + While active, causes the player to move to the left. +See also: +moveright, +left, +strafe + ++moveright, -moveright + While active, causes the player to move to the right. +See also: +moveleft, +right, +strafe + ++moveup, -moveup + Moves the player up if swimming or flying. +See also: +movedown + ++right, -right + While active, normally causes the player to turn to the right. However, as + long as +strafe is active, this will cause the player to move to the right + instead. +See alse: +left, +strafe, +moveright + ++showscores, -showscores + While this action is active and you are playing a deathmatch game, a list + of the frags made by all players will be displayed on the screen. In + deathmatch games, this list will also automatically be display when you + are dead. + ++speed, -speed + While active, all player movements occur at a rate faster than normal. +See also: cl_run + ++strafe, -strafe + While active, causes all +left and +right commands to act like +moveleft + and +moveright instead. +See also: +left, +right, +moveleft, +moveright + ++use, -use + While active, causes the player to attempt to use any usable items in + front of him/her (such as a door). + + +OTHER COMMANDS AND CVARS +======================== +addbot [name] +(command) + Spawns a bot. If a name is given, the corresponding bot in bots.cfg will be + spawned. Otherwise, a bot will be picked at random from bots.cfg. +See also: listbots, removebots + +alias +(command) + If specified with no parameters, will display a list of all current + aliases. If only is specified, it will be removed from the + list of aliases. If is also specified, it will be added + to the list of aliases as . For example, to create a new + command to kill the monsters on the level, you can use the command: + + alias massacre kill monsters + + Then, you can use the newly created massacre command to kill all the + monsters on the level. + +alwaysapplydmflags +(cvar: boolean) +default: 0 + Normally, some dmflags are only used in deathmatch. If alwaysapplydmflags + is 1, then they will also be used in single-player and co-op games. +See also: dmflags + +am_backcolor +(cvar: color) +default: "6c 54 40" (a light tan) + The color of the automap background. Changes to this cvar take effect the + next time the automap is activated. +See also: all the am_* cvars + +am_cdwallcolor +(cvar: color) +default: "4c 38 20" (a dark tan) + The color of two-sided lines that have a different ceiling height on each + side. Changes to this cvar take effect the next time the automap is + activated. +See also: all the am_* cvars + +am_fdwallcolor +(cvar: color) +default: "88 70 58" (a lighter tan) + The color of two-sided lines that have a different floor height on each + side. Changes to this cvar take effect the next time the automap is + activated. +See also: all the am_* cvars + +am_gridcolor +(cvar: color) +default: "8b 5a 2b" (tan4) + The color of the automap grid. Changes to this cvar take effect the next + time the automap is activated. +See also: all the am_* cvars + +am_interlevelcolor +(cvar: color) +default: "ff 00 00" (red) + The color of inter-level teleporters. These are teleporters that teleport + you to a different map. Changes to this cvar take effect the next time the + automap is activated. +See also: all the am_* cvars + +am_intralevelcolor +(cvar: color) +default: "00 00 ff" (blue) + The color of intra-level teleporters. These are teleporters that teleport + you to a different location on the same map. Changes to this cvar take + effect the next time the automap is activated. +See also: all the am_* cvars + +am_lockedcolor +(cvar: color) +default: "00 00 98" (a blue) + The color of lines that open locked doors. Changes to this cvar take + effetc the next time the automap is activated. +See also: all the am_* cvars + +am_notseencolor +(cvar: color) +default: "6c 6c 6c" (somewhat dark gray) + The color of lines on the automap that haven't yet been seen. Visible with + a computer area map. Changes to this cvar take effect the next time the + automap is activated. +See also: all the am_* cvars + +am_overlay +(cvar: boolean) +default: 0 + Normally, the togglemap command switches the automap between fully off and + fully on. Setting this cvar to "1" will cause togglemap to draw the + automap on top of the player's view before it draws the automap + fullscreen. (Bad description, I know. Just try it) +See also: am_rotate, togglemap + +am_ovotherwallscolor +(cvar: color) +default: "00 88 44" (a dark blueish-green) + The color of passable lines on the automap when the map is overlayed. + Changes to this cvar take effect the next time the automap is activated. +See also: all the am_* cvars + +ov_telecolor +(cvar: color) +default: "ff ff 00" (a bright green) + The color of teleports on the overlayed automap. Changes to this cvar take + effect the next time the automap is activated. +See also: all the am_* cvars + +am_ovthingcolor +(cvar: color) +default: "e8 88 00" (an orange) + The color of things visible with the automap cheat when the map is + overlayed. Changes to this cvar take effect the next time the automap is + activated. +See also: all the am_* cvars + +am_ovunseencolor +(cvar: color) +default: "00 22 6e" (a dark greenish-blue) + The color of unseen lines on the automap when the map is overlayed. + Changes to this cvar take effect the next time the automap is activated. +See also: all the am_* cvars + +am_ovwallcolor +(cvar: color) +default: "00 ff 00" (a bright green) + The color of impassable walls when the automap is overlayed. Changes to + this cvar take effect the next time the automap is activated. +See also: all the am_* cvars + +am_ovyourcolor +(cvar: color) +default: "fc e8 d8" (a very light orange--almost white) + The color of the arrow representing the player in single player games when + the map is overlayed. Changes to this cvar take effect the next time the + automap is activated. +See also: all the am_* cvars + +am_rotate +(cvar: boolean) +default: 0 + Normally, the automap is always drawn such that north is at the top of the + screen. Setting this cvar to "1" causes the automap to be drawn so that + lines toward the top of the screen are always directly in front of the + player's view. Changes to this cvar take effect immediately, unlike most + of the other am_* cvars. This can be particularly useful when the automap + is overlayed. +See also: am_overlay + +am_showmonsters +(cvar: boolean) +default: 1 + When true, the fullscreen automap will display a count of the number of + monsters that have been killed in the current level and the total number + of monsters in the level. +See also: am_showtime, am_showsecrets + +am_showsecrets +(cvar: boolean) +default: 1 + When true, the fullscreen automap will display a count of the number of + secrets that have been found in the current level and the total number of + secrets in the level. +See also: am_showmonsters, am_showtime + +am_showtime +(cvar: boolean) +default: 1 + When true, the fullscreen automap will display the total amount of time + you have been in a level (excluding time that has been paused). +See also: am_showmonsters, am_showsecrets + +am_thingcolor +(cvar: color) +default: "fcfc fcfc fcfc" (almost white) + The color of things revealed with the map cheat. Changes to this cvar take + effect the next time the automap is activated. +See also: all the am_* cvars + +am_tswallcolor +(cvar: color) +default: "8888 8888 8888" (gray) + The color of two-sided lines that don't have any difference in floor or + ceiling heights on either side. Only seen using map cheat. Changes to this + cvar take effect the next time the automap is activated. +See also: all the am_* cvars + +am_usecustomcolors +(cvar: boolean) +default: 1 + When true, the automap uses the colors specified by the am_* cvars, + otherwise it uses the standard DOOM automap colors. Changes to this cvar + take effect the next time the automap is activated. +See also: all the am_* cvars + +am_wallcolor +(cvar: color) +default: "2c2c 1818 0808" (a dark brown) + The color of one-sided and secret walls in the automap. Changes to this + cvar take effect the next time the automap is activated. +See also: all the am_* cvars + +am_xhaircolor +(cvar: color) +default: "8080 8080 8080" (gray) + The color of the "crosshair" dot in the center of the automap. Changes to + this cvar take effect the next time the automap is activated. +See also: all the am_* cvars + +am_yourcolor +(cvar: color) +default: "fcfc e8e8 d8d8" (a very light orange--almost white) + The color of the arrow representing the player in single player games. + Changes to this cvar take effect the next time the automap is activated. +See also: all the am_* cvars + +autoaim +(cvar: number) +default: 5000 + This represents the vertical distance from an object that the player's + sight must be before that object is aimed at. Setting this cvar to "0" + disables autoaiming, while large values such as "5000" will reproduce the + original DOOM behavior of always autoaiming. +See also: color, name + +autoexec +(cvar: string) +default: "/autoexec.cfg" + This is a file that will be automatically executed by ZDoom each time it + starts. This file is executed immediately after the config file is loaded. + It should contain a series of console commands. C++ style comments are + also supported. Comments begin with // and anything after them until the + end of the line will be ignored. + + represents the directory that ZDoom is in and will naturally + vary depending on where you put it. + +bind [key [command string]] +(command) + If no parameters are specified, the entire list of bound keys will be + printed to the console. If only [key] is specified, the binding for that + specific key will be printed. If both [key] and [command string] are + specified, [command string] will be bound to [key]. +See also: doublebind, unbind, unbindall, undoublebind + +binddefaults +(command) + Binds all keys to their default commands. This will not unbind any keys + that do not have any default bindings, so if you want to properly restore + the default controls, you need to use unbindall first. +See also: unbindall, bind + +bot_allowspy +(cvar: boolean) +default: 0 + Allows you to see through the eyes of bots during botmatch games. + +bot_next_color +(cvar: number) +default: 11 + Theoretically, a number representing the color of the next bot to be + spawned. In practice, it doesn't do anything. + +bot_observer +(cvar: boolean) +default: 0 + When set to 1, the player will experience minimal interaction with the + world, and bots will ignore him. + +bumpgamma +(command) + Increases the current gamma level by 0.1. If the new gamma level would be + greater than 3.0, it wraps the gamma around to 1.0 +See also: gamma + +centerview +(command) + Causes the player to look straight ahead. +See also: +lookup, +lookdown + +changemap +(command) + Exits the current level and continues the game on the specified map. + Unlike the map and idclev commands, this command *will* work properly + during network games and is recorded in demos. Unfortunately, it has + occasionally resulted in some problems. It should, however, be safe + enough to use most of the time. +See also: idclev, map + +changemus +(command) + Changes the currently playing music. should be the name of a music + lump or file on disk (which need not have been specified with the -file + parameter). +See also: dir, idmus + +chase +(command) + Turns the chasecom on and off. This command also works while watching + demos, so you can bind it to a key and watch demos in the third person. +See also: chase_dist, chase_height, chasedemo + +chase_dist +(cvar: number) +default: 90 + This is how far away from the player the chasecam likes to be, but it will + get closer as necessary to avoid going inside walls. +See also: chase, chase_height + +chase_height +(cvar: number) +default: -8 + This is the base height above the top of the player's head that the + chasecam will be positioned at. Looking up and down will move the camera + in the opposite direction so that the player stays at approximately the + same height on the screen. Large values of this cvar (either positive or + negative) will produce strange output. +See also: chase, chase_dist + +chasedemo +(cvar: boolean) +default: 0 + If this cvar is true, then demos will automatically start with the + chasecam active. +See also: chase + +chatmacro0 +chatmacro1 +chatmacro2 +chatmacro3 +chatmacro4 +chatmacro5 +chatmacro6 +chatmacro7 +chatmacro8 +chatmacro9 +(cvar: string) + These are all strings programmable to the function keys during a netgame. + To use these, enter chat mode with the messagemode command, and then hold + down Alt and press one of the number keys. The string stored in the + corresponding chatmacro cvar will be sent as if you had typed it yourself. + +cl_bloodtype +(cvar: number) +default: 0 + Controls how blood is drawn. Supported values are: + 0: Blood is drawn as sprites + 1: Blood is drawn as both sprites and particles + 2: Blood is drawn as particles + +cl_pufftype +(cvar: number) +default: 0 + Controls how bullet puffs are drawn. Supported values are: + 0: Puffs are drawn as sprites. + 1: Puffs are drawn as particles. + +cl_rockettrails +(cvar: boolean) +default: 1 + Controls whether or not rockets leave trails of smoke behind them. + +cl_run +(cvar: boolean) +default: 0 + When non-zero, the game will always treat movement commands as if +speed + is active. +See also: +speed + +clear +(command) + Clears the console of all text. + +cmdlist +(command) + Lists all commands currently supported by ZDoom. +See also: cvarlist + +color +(cvar: color) +default: "4040 cfcf 0000" (Mostly green) + This is the color of your player's suit. +See also: gender, name, skin, team + +con_midtime +(cvar: number) +default: 3 + This is the number of seconds that messages in the middle of the screen + will be displayed before they dispapper. +See also: con_notifytime + +con_notifytime +(cvar: number) +default: 3 + This is the number of seconds that new messages will stay at the top of + the screen before they start scrolling away. +See also: con_midtime + +con_scaletext +(cvar: boolean) +default: 0 + If this cvar is true, then message text will be scaled to larger sizes + depending on the screen resolution so that it will stay approximately the + same size it would be on a 320x200 screen. + +configver +(cvar: number) +default: "116" + This cvar is used to keep track of which version of ZDoom was used to write + the current config file and adjust for differences that may have been + introduced between versions. Changing it has no effect, since it will + always be changed to reflect the current game version before the config + file is saved. + +crosshair +(cvar: number) +default: 0 + If this cvar is non-zero, it draws a crosshair. If this cvar is negative, + the crosshair is translucent, otherwise it is opaque. The specific + crosshair drawn depends on the value of this cvar. + +cvarlist +(command) + Lists the values of all currently defined cvars. Each cvar can also be + prefaced by multiple flags. These are: + + A Cvar gets saved in the config file. + U Cvar contains user info. + S Cvar contains server info. + - Cvar can only be changed from the command line. + L Changes to cvar's contents don't take effect until the next game. + C Cvar has an internal callback. + * Cvar was created by the user and is meaningless to the game. + +See also: cmdlist, get, set + +deathmatch +(cvar: boolean) +default: 0 + When true, deathmatch rules are used for the game. + +def_patch +(cvar: string) +default: "" + This is the name of a DeHackEd patch file to automatically apply each time + the game is run. It will only be used if the following conditions are met: + + a) def_patch is not "", and the file exists. + b) No loaded WAD files contain a DEHACKED lump. + c) No patch is specified with the -deh command line parameter. + +developer +(cvar: boolean) +default: 0 + When true, prints various debugging messages to the console. + +dimamount +(cvar: number) +default: 1 + This is the amount of dimcolor to mix with the background when a menu is + displayed. The available values are: + 0: Do not dim the background. + 1: Mix 25% of dimcolor with the background. + 2: Mix 50% of dimcolor with the background. + 3: Mix 75% of dimcolor with the background. +See also: dimcolor + +dimcolor +(cvar: color) +default: "ffff d7d7 0000" (gold) + This is the color to mix with the background when a menu is displayed. +See also: dimamount, setcolor + +dir [[path/][pattern]] +(command) + This command lists the contents of a directory. It supports wildcards (but + will not recurse into multiple directories). If [path] is not specified, + it will display the contents of the directory the game was run from. + +deathmatch +(cvar: boolean) +default: 0 + When set to true, the game is treated as a deathmatch. When the game is + started with -altdeath or -deathmatch, this cvar is automatically set to 1. + +dmflags +(cvar: number) +default: 0 + This cvar controls the behavior of several aspects of gameplay. To + determine what value to store in this cvar, select the desired features + from the table below and add their values together. If a feature is + marked with (DM), then that feature will only be active during a + deathmatch game. + + Value Description + ------ ----------------------------------------------------------------- + 1 Do not spawn health items (DM) + 2 Do not spawn powerups (DM) + 4 Leave weapons around after pickup (DM) + 8 Falling too far hurts + 16 Players cannot hurt teammates (friendly fire avoidance) + 64 Stay on the same map when someone exits (DM) + 128 Spawn players as far as possible from other players (DM) + 256 Automatically respawn dead players (DM) + 512 Do not spawn armor (DM) + 1024 Kill anyone who tries to exit the level (DM) + 2048 Don't use any ammo when firing + 4096 Don't spawn monsters + 8192 Monsters respawn sometime after their death + 16384 Powerups other than invulnerability and invisibilty respawn + 32768 Monsters are fast + 65536 Don't allow jumping + 131072 Don't allow freelook + 262144 Invulnerability and invisibility respawn + +See also: menu_gameplay, teamplay + +doublebind [key [command string]] +(command) + If no parameters are specified, the entire list of doublebound keys will be + printed to the console. If only [key] is specified, the doublebinding for + that specific key will be printed. If both [key] and [command string] are + specified, [command string] will be doublebound to [key]. (Doublebindings + are commands that are executed when a key is pressed twice quickly--such as + double cliking a mouse button.) +See also: bind, unbind, unbindall, undoublebind + +dumpheap +(command) + Prints detailed information about the heap. Probably not very useful to + the average user. +See also: mem + +echo +(command) + Prints to the console. + +endgame +(command) + Ends the current single player game and drops the console down to cover the + screen. +See also: menu_endgame + +error +(command) + Simulates an error by killing the current game and falling back to the + fullscreen console with the specified message. + +exec