]> de.git.xonotic.org Git - voretournament/voretournament.git/blob - data/qcsrc/menu/msys.qh
Get VoreTournament code to compile with gmqcc. To be compiled with the same parameter...
[voretournament/voretournament.git] / data / qcsrc / menu / msys.qh
1 //////////////////////////////////////////////////////////\r
2 // sys globals\r
3 \r
4 entity self;\r
5 \r
6 /////////////////////////////////////////////////////////\r
7 void            end_sys_globals;\r
8 /////////////////////////////////////////////////////////\r
9 // sys fields\r
10 \r
11 /////////////////////////////////////////////////////////\r
12 void            end_sys_fields;\r
13 /////////////////////////////////////////////////////////\r
14 // sys functions\r
15 \r
16 void() m_init;\r
17 void(float keynr, float ascii) m_keydown;\r
18 void() m_draw;\r
19 void() m_display;       // old NG Menu\r
20 void() m_toggle;\r
21 void() m_hide;          // old NG Menu\r
22 void() m_shutdown;\r
23 \r
24 /////////////////////////////////////////////////////////\r
25 // sys constants\r
26 \r
27 ///////////////////////////\r
28 // key dest constants\r
29 \r
30 float KEY_UNKNOWN       =       -1;\r
31 float KEY_GAME          =       0;\r
32 float KEY_MENU          =       2;\r
33 float KEY_MENU_GRABBED = 3;\r
34 \r
35 ///////////////////////////\r
36 // file constants\r
37 \r
38 float FILE_READ = 0;\r
39 float FILE_APPEND = 1;\r
40 float FILE_WRITE = 2;\r
41 \r
42 ///////////////////////////\r
43 // logical constants (just for completeness)\r
44 \r
45 float TRUE      = 1;\r
46 float FALSE = 0;\r
47 \r
48 ///////////////////////////\r
49 // boolean constants\r
50 \r
51 float true  = 1;\r
52 float false = 0;\r
53 \r
54 ///////////////////////////\r
55 // msg constants\r
56 \r
57 float MSG_BROADCAST             = 0;            // unreliable to all\r
58 float MSG_ONE                   = 1;            // reliable to one (msg_entity)\r
59 float MSG_ALL                   = 2;            // reliable to all\r
60 float MSG_INIT                  = 3;            // write to the init string\r
61 \r
62 /////////////////////////////\r
63 // mouse target constants\r
64 \r
65 float MT_MENU = 1;\r
66 float MT_CLIENT = 2;\r
67 \r
68 /////////////////////////\r
69 // client state constants\r
70 \r
71 float CS_DEDICATED              = 0;\r
72 float CS_DISCONNECTED   = 1;\r
73 float CS_CONNECTED              = 2;\r
74 \r
75 ///////////////////////////\r
76 // blend flags\r
77 \r
78 float DRAWFLAG_NORMAL           = 0;\r
79 float DRAWFLAG_ADDITIVE         = 1;\r
80 float DRAWFLAG_MODULATE         = 2;\r
81 float DRAWFLAG_2XMODULATE   = 3;\r
82 \r
83 \r
84 ///////////////////////////\r
85 // server list constants\r
86 \r
87 float SLIST_HOSTCACHEVIEWCOUNT  = 0;\r
88 float SLIST_HOSTCACHETOTALCOUNT = 1;\r
89 float SLIST_MASTERQUERYCOUNT    = 2;\r
90 float SLIST_MASTERREPLYCOUNT    = 3;\r
91 float SLIST_SERVERQUERYCOUNT    = 4;\r
92 float SLIST_SERVERREPLYCOUNT    = 5;\r
93 float SLIST_SORTFIELD           = 6;\r
94 float SLIST_SORTDESCENDING      = 7;\r
95 \r
96 float SLIST_LEGACY_LINE1        = 1024;\r
97 float SLIST_LEGACY_LINE2        = 1025;\r
98 \r
99 float SLIST_TEST_CONTAINS       = 0;\r
100 float SLIST_TEST_NOTCONTAIN     = 1;\r
101 float SLIST_TEST_LESSEQUAL      = 2;\r
102 float SLIST_TEST_LESS           = 3;\r
103 float SLIST_TEST_EQUAL          = 4;\r
104 float SLIST_TEST_GREATER        = 5;\r
105 float SLIST_TEST_GREATEREQUAL   = 6;\r
106 float SLIST_TEST_NOTEQUAL       = 7;\r
107 float SLIST_TEST_STARTSWITH     = 8;\r
108 float SLIST_TEST_NOTSTARTSWITH  = 9;\r
109 \r
110 float SLIST_MASK_AND = 0;\r
111 float SLIST_MASK_OR  = 512;\r
112 \r
113 float NET_CURRENTPROTOCOL = 3;\r
114 \r
115 ////////////////////////////////\r
116 // cinematic action constants\r
117 \r
118 float CINE_PLAY         = 1;\r
119 float CINE_LOOP         = 2;\r
120 float CINE_PAUSE        = 3;\r
121 float CINE_FIRSTFRAME   = 4;\r
122 float CINE_RESETONWAKEUP= 5;\r
123 \r
124 ///////////////////////////\r
125 // null entity (actually it is the same like the world entity)\r
126 \r
127 entity null_entity;\r
128 \r
129 ///////////////////////////\r
130 // error constants\r
131 \r
132 // file handling\r
133 float ERR_CANNOTOPEN                    = -1; // fopen\r
134 float ERR_NOTENOUGHFILEHANDLES  = -2; // fopen\r
135 float ERR_INVALIDMODE                   = -3; // fopen\r
136 float ERR_BADFILENAME                   = -4; // fopen\r
137 \r
138 // drawing functions\r
139 \r
140 float ERR_NULLSTRING                    = -1;\r
141 float ERR_BADDRAWFLAG                   = -2;\r
142 float ERR_BADSCALE                      = -3;\r
143 //float ERR_BADSIZE                     = ERR_BADSCALE;\r
144 float ERR_NOTCACHED                     = -4;\r
145 \r
146 float GECKO_BUTTON_DOWN                 = 0;\r
147 float GECKO_BUTTON_UP                   = 1;\r
148 // either use down and up or just press but not all of them!\r
149 float GECKO_BUTTON_PRESS                = 2;\r
150 // use this for mouse events if needed?\r
151 float GECKO_BUTTON_DOUBLECLICK  = 3;\r
152 \r
153 /* not supported at the moment\r
154 ///////////////////////////\r
155 // os constants\r
156 \r
157 float OS_WINDOWS        = 0;\r
158 float OS_LINUX          = 1;\r
159 float OS_MAC            = 2;\r
160 */\r
161 \r
162 float drawfont; // set this to one of the following for draw text routines to work with another font\r
163 float FONT_DEFAULT     = 0;\r
164 float FONT_CONSOLE     = 1;\r
165 float FONT_SBAR        = 2;\r
166 float FONT_NOTIFY      = 3;\r
167 float FONT_CHAT        = 4;\r
168 float FONT_CENTERPRINT = 5;\r
169 float FONT_INFOBAR     = 6;\r
170 float FONT_MENU        = 7;\r
171 float FONT_USER        = 8; // add to this the index, like FONT_USER+3 = user3. At least 8 of them are supported.\r