]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blob - qcsrc/common/constants.qh
6fd6fe9c7e97233023d7a530a812462140659e8e
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / constants.qh
1 #pragma once
2
3 const int RANKINGS_CNT = 15;
4
5 const int SPRITERULE_DEFAULT = 0;
6 const int SPRITERULE_TEAMPLAY = 1;
7 const int SPRITERULE_SPECTATOR = 2;
8
9 ///////////////////////////
10 // keys pressed
11 const int KEY_FORWARD = BIT(0);
12 const int KEY_BACKWARD = BIT(1);
13 const int KEY_LEFT = BIT(2);
14 const int KEY_RIGHT = BIT(3);
15 const int KEY_JUMP = BIT(4);
16 const int KEY_CROUCH = BIT(5);
17 const int KEY_ATCK = BIT(6);
18 const int KEY_ATCK2 = BIT(7);
19
20 ///////////////////////////
21 // cvar constants
22
23 const int CVAR_SAVE = 1;
24 const int CVAR_NOTIFY = 2;
25 const int CVAR_READONLY = 4;
26
27 ///////////////////////////
28 // csqc communication stuff
29
30 const int HUD_NORMAL = 0;
31 const int HUD_BUMBLEBEE_GUN = 25;
32
33 // moved that here so the client knows the max.
34 // # of maps, I'll use arrays for them :P
35 const int MAPVOTE_COUNT = 30;
36
37 // game mode specific indices are not in common/, but in server/scores_rules.qc!
38
39 const int SPECIES_HUMAN = 0;
40 const int SPECIES_ROBOT_SOLID = 1;
41 const int SPECIES_ALIEN = 2;
42 const int SPECIES_ANIMAL = 3;
43 const int SPECIES_ROBOT_RUSTY = 4;
44 const int SPECIES_ROBOT_SHINY = 5;
45 const int SPECIES_RESERVED = 15;
46
47 const int FRAGS_PLAYER = 0;
48 const int FRAGS_SPECTATOR = -666;
49 const int FRAGS_LMS_LOSER = -616;
50 const int FRAGS_PLAYER_NONSOLID = FRAGS_LMS_LOSER;
51 // we can use this frags value for both
52
53 // water levels
54 const int WATERLEVEL_NONE = 0;
55 const int WATERLEVEL_WETFEET = 1;
56 const int WATERLEVEL_SWIMMING = 2;
57 const int WATERLEVEL_SUBMERGED = 3;
58
59 // server flags
60 const int SERVERFLAG_ALLOW_FULLBRIGHT = 1;
61 const int SERVERFLAG_TEAMPLAY = 2;
62 const int SERVERFLAG_PLAYERSTATS = 4;
63
64 #ifdef SVQC
65 // FIXME/EXPLAINME: why? Mario: because
66 vector autocvar_sv_player_maxs = '16 16 45';
67 vector autocvar_sv_player_mins = '-16 -16 -24';
68 vector autocvar_sv_player_viewoffset = '0 0 35';
69 vector autocvar_sv_player_crouch_maxs = '16 16 25';
70 vector autocvar_sv_player_crouch_mins = '-16 -16 -24';
71 vector autocvar_sv_player_crouch_viewoffset = '0 0 20';
72 //vector autocvar_sv_player_headsize = '24 24 12';
73
74 // temporary array used to dump weapon and turret settings
75 const int MAX_CONFIG_SETTINGS = 256;
76 string config_queue[MAX_CONFIG_SETTINGS];
77
78 #endif
79
80
81 // a bit more constant
82 const vector PL_MAX_CONST = '16 16 45';
83 const vector PL_MIN_CONST = '-16 -16 -24';
84
85 // spawnpoint prios
86 const int SPAWN_PRIO_NEAR_TEAMMATE_FOUND = 200;
87 const int SPAWN_PRIO_NEAR_TEAMMATE_SAMETEAM = 100;
88 const int SPAWN_PRIO_RACE_PREVIOUS_SPAWN = 50;
89 const int SPAWN_PRIO_GOOD_DISTANCE = 10;
90
91 // gametype vote flags
92 const int GTV_FORBIDDEN = 0; // Cannot be voted
93 const int GTV_AVAILABLE = 1; // Can be voted
94 const int GTV_CUSTOM    = 2; // Custom entry