]> git.cameronkatri.com Git - bsdgames-darwin.git/blob - warp/us.h
cgram: properly handle input errors
[bsdgames-darwin.git] / warp / us.h
1 /* Header: us.h,v 7.0.1.1 86/10/16 10:53:58 lwall Exp */
2
3 /* Log: us.h,v
4 * Revision 7.0.1.1 86/10/16 10:53:58 lwall
5 * Added Damage. Fixed random bugs.
6 *
7 * Revision 7.0 86/10/08 15:14:27 lwall
8 * Split into separate files. Added amoebas and pirates.
9 *
10 */
11
12 EXT bool cloaking;
13 EXT bool cloaked;
14
15 EXT int status;
16 EXT int entmode;
17
18 EXT int evely;
19 EXT int evelx;
20 EXT int bvely;
21 EXT int bvelx;
22
23 #define MAXDAMAGE 9
24 #define NOWARP 0
25 #define NOIMPULSE 1
26 #define NOPHASERS 2
27 #define NOTORPS 3
28 #define NOCLOAKING 4
29 #define NOSHIELDS 5
30 #define NOZAPPER 6
31 #define NODESTRUCT 7
32 #define NOTRACTORS 8
33
34 EXT int dam INIT(0);
35 EXT int lastdam INIT(-1);
36 EXT int damage INIT(0);
37 EXT int olddamage INIT(-1);
38
39 #ifdef DOINIT
40 const char *dammess[MAXDAMAGE] = {
41 "WARP",
42 "IMPULSE",
43 "PHASERS",
44 "TORPS",
45 "CLOAKING",
46 "SHIELDS",
47 "ZAPPER",
48 "DESTRUCT",
49 "TRACTORS"
50 };
51 char damflag[MAXDAMAGE] = {0,0,0,0,0,0,0,0,0};
52 #else
53 extern char *dammess[];
54 extern char damflag[];
55 #endif
56
57 void us_init(void);
58 void do_direction(int, int);
59 void ctrl_direction(int, int);
60 void shift_direction(int, int);
61 void get_commands(bool *);