1 /* Emacs style mode select -*- C++ -*-
2 *-----------------------------------------------------------------------------
5 * PrBoom a Doom port merged with LxDoom and LSDLDoom
6 * based on BOOM, a modified and improved DOOM engine
7 * Copyright (C) 1999 by
8 * id Software, Chi Hoang, Lee Killough, Jim Flynn, Rand Phares, Ty Halderman
9 * Copyright (C) 1999-2000 by
10 * Jess Haas, Nicolas Kalkhof, Colin Phipps, Florian Schulze
12 * This program is free software; you can redistribute it and/or
13 * modify it under the terms of the GNU General Public License
14 * as published by the Free Software Foundation; either version 2
15 * of the License, or (at your option) any later version.
17 * This program is distributed in the hope that it will be useful,
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 * GNU General Public License for more details.
22 * You should have received a copy of the GNU General Public License
23 * along with this program; if not, write to the Free Software
24 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
28 * Internally used data structures for virtually everything,
29 * key definitions, lots of other stuff.
31 *-----------------------------------------------------------------------------*/
36 #include "rockmacros.h"
38 // killough 4/25/98: Make gcc extensions mean nothing on other compilers
40 #define __attribute__(x)
44 // Global parameters/defines.
47 enum { DVERSION
= 110 };
49 // Game mode handling - identify IWAD version
50 // to handle IWAD dependend animations etc.
52 shareware
, // DOOM 1 shareware, E1, M9
53 registered
, // DOOM 1 registered, E3, M27
54 commercial
, // DOOM 2 retail, E1 M34 (DOOM 2 german edition not handled)
55 retail
, // DOOM 1 retail, E4, M36
56 indetermined
// Well, no IWAD found.
59 // Mission packs - might be useful for TC stuff?
63 pack_tnt
, // TNT mission pack
64 pack_plut
, // Plutonia pack
68 // Identify language to use, software localization.
77 // For resize of screen, at start of game.
80 #define BASE_WIDTH 320
82 // It is educational but futile to change this
83 // scaling e.g. to 2. Drawing of status bar,
84 // menues etc. is tied to the scale implied
87 #define INV_ASPECT_RATIO 0.625 // 0.75, ideally
89 // killough 2/8/98: MAX versions for maximum screen sizes
90 // allows us to avoid the overhead of dynamic allocation
91 // when multiple screen sizes are supported
93 #if(LCD_HEIGHT>LCD_WIDTH)
94 extern bool rotate_screen
;
95 // proff 08/17/98: Changed for high-res
96 #define MAX_SCREENWIDTH LCD_HEIGHT
97 #define MAX_SCREENHEIGHT LCD_HEIGHT
98 extern int SCREENWIDTH
;
99 extern int SCREENHEIGHT
;
101 // proff 08/17/98: Changed for high-res
102 #define MAX_SCREENWIDTH LCD_WIDTH
103 #define MAX_SCREENHEIGHT LCD_HEIGHT
104 #define SCREENWIDTH LCD_WIDTH
105 #define SCREENHEIGHT LCD_HEIGHT
108 // The maximum number of players, multiplayer/networking.
112 // DOOM Editor Numbers (aka doomednum in mobj_t)
114 #define DEN_PLAYER5 4001
115 #define DEN_PLAYER6 4002
116 #define DEN_PLAYER7 4003
117 #define DEN_PLAYER8 4004
119 // State updates, number of tics / second.
122 // The current state of the game: whether we are playing, gazing
123 // at the intermission screen, the game final animation, or a demo.
133 // Difficulty/skill settings/filters.
140 // Deaf monsters/do not react to sound.
144 #define MTF_NOTSINGLE 16
146 #define MTF_NOTCOOP 64
147 #define MTF_FRIEND 128
148 #define MTF_RESERVED 256
151 sk_none
=-1, //jff 3/24/98 create unpicked skill setting
173 // The defined weapons, including a marker
174 // indicating user has not changed weapon.
187 wp_nochange
// No pending weapon change.
190 // Ammunition types defined.
192 am_clip
, // Pistol / chaingun ammo.
193 am_shell
, // Shotgun / double barreled shotgun.
194 am_cell
, // Plasma rifle, BFG.
195 am_misl
, // Missile launcher.
197 am_noammo
// Unlimited for chainsaw / fist.
200 // Power up artifacts.
211 // Power up durations (how many seconds till expiration).
213 INVULNTICS
= (30*TICRATE
),
214 INVISTICS
= (60*TICRATE
),
215 INFRATICS
= (120*TICRATE
),
216 IRONTICS
= (60*TICRATE
)
220 // DOOM keyboard definition.
221 // This is the stuff configured by Setup.Exe.
222 // Most key data are simple ascii (uppercased).
224 #define KEY_RIGHTARROW 0xae
225 #define KEY_LEFTARROW 0xac
226 #define KEY_UPARROW 0xad
227 #define KEY_DOWNARROW 0xaf
228 #define KEY_ESCAPE 0x1B
229 #define KEY_ENTER 0x60 // Changed due to button reconfig - 0x0D
230 #define KEY_TAB 0x61 // Changed due to button reconfig - 0x09
231 #define KEY_F1 (0x80+0x3b)
232 #define KEY_F2 (0x80+0x3c)
233 #define KEY_F3 (0x80+0x3d)
234 #define KEY_F4 (0x80+0x3e)
235 #define KEY_F5 (0x80+0x3f)
236 #define KEY_F6 (0x80+0x40)
237 #define KEY_F7 (0x80+0x41)
238 #define KEY_F8 (0x80+0x42)
239 #define KEY_F9 (0x80+0x43)
240 #define KEY_F10 (0x80+0x44)
241 #define KEY_F11 (0x80+0x57)
242 #define KEY_F12 (0x80+0x58)
243 #define KEY_BACKSPACE 0x7F
244 #define KEY_PAUSE 0xff
245 #define KEY_EQUALS 0x3d
246 #define KEY_MINUS 0x2d
247 #define KEY_RSHIFT (0x80+0x36)
248 #define KEY_RCTRL (0x80+0x1d)
249 #define KEY_RALT (0x80+0x38)
250 #define KEY_LALT KEY_RALT
251 #define KEY_CAPSLOCK 0xba // phares
254 #define KEY_INSERT 0xd2
255 #define KEY_HOME 0xc7
256 #define KEY_PAGEUP 0xc9
257 #define KEY_PAGEDOWN 0xd1
260 #define KEY_SCROLLLOCK 0xc6
261 #define KEY_SPACEBAR 0x20
264 #define KEY_NUMLOCK 0xC5 // killough 3/6/98
266 // cph - Add the numeric keypad keys, as suggested by krose 4/22/99:
267 // The way numbers are assigned to keys is a mess, but it's too late to
268 // change that easily. At least these additions are don neatly.
269 // Codes 0x100-0x200 are reserved for number pad
271 #define KEY_KEYPAD0 (0x100 + '0')
272 #define KEY_KEYPAD1 (0x100 + '1')
273 #define KEY_KEYPAD2 (0x100 + '2')
274 #define KEY_KEYPAD3 (0x100 + '3')
275 #define KEY_KEYPAD4 (0x100 + '4')
276 #define KEY_KEYPAD5 (0x100 + '5')
277 #define KEY_KEYPAD6 (0x100 + '6')
278 #define KEY_KEYPAD7 (0x100 + '7')
279 #define KEY_KEYPAD8 (0x100 + '8')
280 #define KEY_KEYPAD9 (0x100 + '9')
281 #define KEY_KEYPADENTER (0x100 + KEY_ENTER)
282 #define KEY_KEYPADDIVIDE (0x100 + '/')
283 #define KEY_KEYPADMULTIPLY (0x100 + '*')
284 #define KEY_KEYPADMINUS (0x100 + '-')
285 #define KEY_KEYPADPLUS (0x100 + '+')
286 #define KEY_KEYPADPERIOD (0x100 + '.')
289 // Defines Setup Screen groups that config variables appear in.
290 // Used when resetting the defaults for every item in a Setup group.
301 ss_gen
, /* killough 10/98 */
302 ss_comp
, /* killough 10/98 */
308 // Player friction is variable, based on controlling
309 // linedefs. More friction can create mud, sludge,
310 // magnetized floors, etc. Less friction can create ice.
312 #define MORE_FRICTION_MOMENTUM 15000 // mud factor based on momentum
313 #define ORIG_FRICTION 0xE800 // original value
314 #define ORIG_FRICTION_FACTOR 2048 // original value
316 #endif // __DOOMDEF__