]> icculus.org git repositories - btb/d2x.git/blob - main/concntl.h
implement all controls as console commands.
[btb/d2x.git] / main / concntl.h
1 #ifndef _CONCNTL_H_
2 #define _CONCNTL_H_ 1
3
4 #include "fix.h"
5
6
7 #define CONCNTL_NUM_CONTROLS 29
8
9 typedef enum
10 {
11         CONCNTL_LOOKDOWN,   // Pitch forward
12         CONCNTL_LOOKUP,     // Pitch backward
13         CONCNTL_LEFT,       // Turn left
14         CONCNTL_RIGHT,      // Turn right
15         CONCNTL_STRAFE,     // Slide on
16         CONCNTL_MOVELEFT,   // Slide left
17         CONCNTL_MOVERIGHT,  // Slide right
18         CONCNTL_MOVEUP,     // Slide up
19         CONCNTL_MOVEDOWN,   // Slide down
20         CONCNTL_BANK,       // Bank on
21         CONCNTL_BANKLEFT,   // Bank left
22         CONCNTL_BANKRIGHT,  // Bank right
23         CONCNTL_ATTACK,     // Fire primary
24         CONCNTL_ATTACK2,    // Fire secondary
25         CONCNTL_FLARE,      // Fire flare
26         CONCNTL_FORWARD,    // Accelerate
27         CONCNTL_BACK,       // Reverse
28         CONCNTL_BOMB,       // Drop bomb
29         CONCNTL_REARVIEW,   // Rear view
30         CONCNTL_CRUISEUP,   // Cruise faster
31         CONCNTL_CRUISEDOWN, // Cruise slower
32         CONCNTL_CRUISEOFF,  // Cruise off
33         CONCNTL_AUTOMAP,    // Automap
34         CONCNTL_AFTERBURN,  // Afterburner
35         CONCNTL_CYCLE,      // Cycle primary
36         CONCNTL_CYCLE2,     // Cycle secondary
37         CONCNTL_HEADLIGHT,  // Headlight
38         CONCNTL_NRGSHIELD,  // Energy->Shield
39         CONCNTL_TOGGLEBOMB, // Toggle bomb
40 } console_control;
41
42
43 fix console_control_down_time(console_control control);
44 unsigned int console_control_down_count(console_control control);
45 unsigned int console_control_up_count(console_control control);
46 unsigned int console_control_state(console_control control);
47 void console_control_init(void);
48
49
50 #endif