]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blob - qcsrc/client/main.qh
stuff.
[xonotic/xonotic-data.pk3dir.git] / qcsrc / client / main.qh
1 // --------------------------------------------------------------------------
2 // MENU Functionality
3
4 #define DATABUF_PING 0
5 #define DATABUF_CAPTURES (1*maxclients)
6 #define DATABUF_DEATHS (2*maxclients)
7 #define DATABUF_RETURNS (3*maxclients)
8
9 #define DATABUF_NEXT (5*maxclients)
10
11 void() menu_show_error;
12 void() menu_sub_null;
13
14 float menu_visible;
15 var void() menu_show;
16 var float(float bInputType, float nPrimary, float nSecondary) menu_action;
17
18 // --------------------------------------------------------------------------
19 // Onslaught
20
21 // Map coordinate base calculations need these
22 vector mi_center;
23 vector mi_scale;
24 // Minimap
25 string minimapname;
26
27 // --------------------------------------------------------------------------
28 // General stuff
29
30 float drawfont;
31 float postinit;
32 float gametype;
33
34 //float sorted_players;
35 //float sorted_teams;
36
37 // Defs
38 //.float ctf_state;
39 //.float health;
40
41 // Constants
42 const float COLOR_TEAM_RED = 64;
43 const float COLOR_TEAM_BLUE = 208;
44
45 const float COLOR_TEAM1       = 4;  // red
46 const float COLOR_TEAM2       = 13; // blue
47 const float COLOR_TEAM3       = 12; // yellow
48 const float COLOR_TEAM4       = 9; // pink
49 const float COLOR_SPECTATOR = 1337;
50
51 #define FONT_DEFAULT 0
52 #define FONT_USER 8
53
54 // --------------------------------------------------------------------------
55 // Scoreboard stuff
56
57 #define MAX_HUD_FIELDS 16
58
59 #define SP_END -1
60
61 #define SP_PING -2
62 #define SP_NAME -3
63 #define SP_KDRATIO -4
64 #define SP_CLRATIO -5
65 #define SP_PL -6
66 #define SP_FRAGS -7
67
68 #define SP_SEPARATOR -100
69
70 float hud_field[MAX_HUD_FIELDS + 1];
71 float hud_size[MAX_HUD_FIELDS + 1];
72 string hud_title[MAX_HUD_FIELDS + 1];
73 float hud_num_fields;
74
75 string scores_label[MAX_SCORE];
76 float scores_flags[MAX_SCORE];
77 string teamscores_label[MAX_SCORE];
78 float teamscores_flags[MAX_SCORE];
79 .float scores[MAX_SCORE];
80 .float teamscores[MAX_TEAMSCORE];
81
82 #define IS_INCREASING(x) ( (x)&SFL_LOWER_IS_BETTER )
83 #define IS_DECREASING(x) ( !((x)&SFL_LOWER_IS_BETTER) )
84
85
86 vector hud_fontsize;
87
88 float RANKINGS_RECEIVED_CNT;
89 string grecordholder[RANKINGS_CNT];
90 float grecordtime[RANKINGS_CNT];
91 //float csqc_flags;
92
93 entity playerslots[255]; // 255 is engine limit on maxclients
94 entity teamslots[17];    // 17 teams (including "spectator team")
95 .float gotscores;
96 .entity owner;
97 .float ready;
98
99 .void(void) draw;
100 .void(void) draw2d;
101 .void(void) entremove;
102 float drawframetime;
103 vector view_origin, view_angles, view_forward, view_right, view_up;
104
105 float button_zoom;
106 float spectatorbutton_zoom;
107 float button_attack2;
108
109 float activeweapon;
110 float switchingweapon;
111 float switchweapon;
112 float current_viewzoom;
113 float zoomin_effect;
114 float warmup_stage;
115
116 string getcommandkey(string text, string command);
117
118 string vote_called_vote;
119 float ready_waiting;
120 float ready_waiting_for_me;
121 float vote_waiting;
122 float vote_waiting_for_me;
123
124 float current_zoomfraction;
125
126 float cs_project_is_b0rked;
127 float vid_width, vid_height, vid_pixelheight;
128
129 float camera_active;            // Demo camera is active if set to TRUE
130 float chase_active_backup;
131 float camera_roll;
132 vector camera_direction;
133
134 void centerprint_hud(string strMessage);
135 void centerprint_generic(float new_id, string strMessage, float duration, float countdown_num);
136
137 #define ALPHA_MIN_VISIBLE 0.003
138
139 float armorblockpercent;
140 float g_weaponswitchdelay;
141
142 //hooks
143 float calledhooks;
144 #define HOOK_START    1
145 #define HOOK_END      2
146
147 .float ping, ping_packetloss, ping_movementloss;
148
149 float g_balance_grenadelauncher_bouncefactor;
150 float g_balance_grenadelauncher_bouncestop;
151 float g_balance_electro_secondary_bouncefactor;
152 float g_balance_electro_secondary_bouncestop;
153 float g_trueaim_minrange;
154
155 entity entcs_receiver[255]; // 255 is the engine limit on maxclients
156
157 float hud;
158 float view_quality;
159 float framecount;