X-Git-Url: https://de.git.xonotic.org/?p=xonotic%2Fxonotic-data.pk3dir.git;a=blobdiff_plain;f=qcsrc%2Fclient%2Fmain.qh;h=ab3758ee8531a2119c555600eb9f7110f5258f99;hp=49a92bb45ca483a399ea675076121a345fb7afa4;hb=10c0e93c75ef6f408e3357bd5fb46c721e7e0576;hpb=f1a87492d9fed27a64d0e99c068705aba5509f26 diff --git a/qcsrc/client/main.qh b/qcsrc/client/main.qh index 49a92bb45..ab3758ee8 100644 --- a/qcsrc/client/main.qh +++ b/qcsrc/client/main.qh @@ -1,19 +1,11 @@ -#ifndef CLIENT_MAIN_H -#define CLIENT_MAIN_H +#pragma once -#include "../common/constants.qh" -#include "../common/weapons/all.qh" +#include +#include // -------------------------------------------------------------------------- // MENU Functionality -const float DATABUF_PING = 0; -#define DATABUF_CAPTURES (1*maxclients) -#define DATABUF_DEATHS (2*maxclients) -#define DATABUF_RETURNS (3*maxclients) - -#define DATABUF_NEXT (5*maxclients) - // -------------------------------------------------------------------------- // Onslaught @@ -38,39 +30,23 @@ float gametype; float FONT_USER = 8; -// -------------------------------------------------------------------------- -// Scoreboard stuff - -const int MAX_HUD_FIELDS = 16; -const int SP_END = -1; +vector OFFSET_CURSOR = '0 0 0'; +vector SIZE_CURSOR = '32 32 0'; +void draw_cursor(vector pos, vector ofs, string img, vector col, float a); +void draw_cursor_normal(vector pos, vector col, float a); +void LoadMenuSkinValues(); -const int SP_PING = -2; -const int SP_NAME = -3; -const int SP_KDRATIO = -4; -const int SP_CLRATIO = -5; -const int SP_PL = -6; -const int SP_FRAGS = -7; -const int SP_SUM = -8; +// -------------------------------------------------------------------------- +// Scoreboard stuff -const int SP_SEPARATOR = -100; +const int MAX_HUD_FIELDS = MAX_SCORE; -float hud_field[MAX_HUD_FIELDS + 1]; +PlayerScoreField hud_field[MAX_HUD_FIELDS + 1]; float hud_size[MAX_HUD_FIELDS + 1]; string hud_title[MAX_HUD_FIELDS + 1]; int hud_num_fields; -string scores_label[MAX_SCORE]; -int scores_flags[MAX_SCORE]; -string teamscores_label[MAX_SCORE]; -int teamscores_flags[MAX_SCORE]; -.int scores[MAX_SCORE]; -.float teamscores[MAX_TEAMSCORE]; - -#define IS_INCREASING(x) ( (x)&SFL_LOWER_IS_BETTER ) -#define IS_DECREASING(x) ( !((x)&SFL_LOWER_IS_BETTER) ) - - vector hud_fontsize; float RANKINGS_RECEIVED_CNT; @@ -87,7 +63,7 @@ entity teamslots[17]; // 17 teams (including "spectator team") .void(entity) draw; .void(entity) draw2d; -.void() entremove; +.void(entity) entremove; float drawframetime; vector view_origin, view_forward, view_right, view_up; @@ -123,6 +99,7 @@ float camera_roll; vector camera_direction; void centerprint_hud(string strMessage); +void centerprint_kill(float id); void centerprint_generic(float new_id, string strMessage, float duration, float countdown_num); const float ALPHA_MIN_VISIBLE = 0.003; @@ -142,5 +119,3 @@ float hud; float view_quality; int framecount; .float health; - -#endif