]> git.lizzy.rs Git - plan9front.git/blob - sys/src/games/doom/doomtype.h
games/doom: fix unterminated comment causing sound bugs (from qu7uux)
[plan9front.git] / sys / src / games / doom / doomtype.h
1 // Emacs style mode select   -*- C++ -*- 
2 //-----------------------------------------------------------------------------
3 //
4 // $Id:$
5 //
6 // Copyright (C) 1993-1996 by id Software, Inc.
7 //
8 // This source is available for distribution and/or modification
9 // only under the terms of the DOOM Source Code License as
10 // published by id Software. All rights reserved.
11 //
12 // The source is distributed in the hope that it will be useful,
13 // but WITHOUT ANY WARRANTY; without even the implied warranty of
14 // FITNESS FOR A PARTICULAR PURPOSE. See the DOOM Source Code License
15 // for more details.
16 //
17 // DESCRIPTION:
18 //      Simple basic typedefs, isolated here to make it easier
19 //       separating modules.
20 //    
21 //-----------------------------------------------------------------------------
22
23
24 #ifndef __DOOMTYPE__
25 #define __DOOMTYPE__
26
27
28 #ifndef __BYTEBOOL__
29 #define __BYTEBOOL__
30 // Fixed to use builtin bool type with C++.
31 #ifdef __cplusplus
32 typedef bool boolean;
33 #else
34 typedef enum {false, true} boolean;
35 #endif
36 typedef unsigned char byte;
37 #endif
38
39
40 // Predefined with some OS.
41 #ifdef LINUX
42 #include <values.h>
43 #else
44 #define MAXCHAR         ((char)0x7f)
45 #define MAXSHORT        ((short)0x7fff)
46
47 // Max pos 32-bit int.
48 #define MAXINT          ((int)0x7fffffff)       
49 #define MAXLONG         ((long)0x7fffffff)
50 #define MINCHAR         ((char)0x80)
51 #define MINSHORT        ((short)0x8000)
52
53 // Max negative 32-bit integer.
54 #define MININT          ((int)0x80000000)       
55 #define MINLONG         ((long)0x80000000)
56 #endif
57
58
59
60
61 #endif
62 //-----------------------------------------------------------------------------
63 //
64 // $Log:$
65 //
66 //-----------------------------------------------------------------------------