]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Add dedicated cvar (hud_panel_healtharmor_combined) for combining health and armor...
authorterencehill <piuntn@gmail.com>
Wed, 30 Mar 2016 22:48:38 +0000 (00:48 +0200)
committerterencehill <piuntn@gmail.com>
Wed, 30 Mar 2016 22:48:38 +0000 (00:48 +0200)
12 files changed:
_hud_descriptions.cfg
hud_luma.cfg
hud_luminos.cfg
hud_luminos_minimal.cfg
hud_luminos_minimal_xhair.cfg
hud_luminos_old.cfg
hud_nexuiz.cfg
qcsrc/client/autocvars.qh
qcsrc/client/hud/hud_config.qc
qcsrc/client/hud/panel/healtharmor.qc
qcsrc/menu/xonotic/dialog_hudpanel_healtharmor.qc
qcsrc/menu/xonotic/dialog_hudpanel_healtharmor.qh

index 970d6ff7f3ed1c24407957f2b5ee8dac491b6e94..adcc7fddc6194a96ab22d6198d963b9908b5e29d 100644 (file)
@@ -99,9 +99,10 @@ seta hud_panel_powerups_bg_padding "" "if set to something else than \"\" = over
 seta hud_panel_powerups_progressbar "" "enable progressbar in panel"
 seta hud_panel_powerups_text "" "show text and icons in the powerups panel"
 
-seta hud_panel_healtharmor "" "enable/disable this panel, 2 = combined health/armor display"
+seta hud_panel_healtharmor "" "enable/disable this panel"
 seta hud_panel_healtharmor_pos "" "position of this panel"
 seta hud_panel_healtharmor_size "" "size of this panel"
+seta hud_panel_healtharmor_combined "" "combined health/armor display"
 seta hud_panel_healtharmor_flip "" "flip health/armor positions"
 seta hud_panel_healtharmor_baralign "" "0 = align bars to the left, 1 = align bars to the right, 2 = align only left bar to the right, 3 = align only right bar to the right"
 seta hud_panel_healtharmor_iconalign "" "0 = align icons to the left, 1 = align icons to the right, 2 = align only left icon to the right, 3 = align only right icon to the right"
index 226af4c1bf237ff596b4128c9621d410d1e8df5f..ae46196344dd41183cac09b7f5d438dc8ae055a7 100644 (file)
@@ -109,6 +109,7 @@ seta hud_panel_healtharmor_bg_color_team ""
 seta hud_panel_healtharmor_bg_alpha ""
 seta hud_panel_healtharmor_bg_border "4"
 seta hud_panel_healtharmor_bg_padding ""
+seta hud_panel_healtharmor_combined "0"
 seta hud_panel_healtharmor_flip "0"
 seta hud_panel_healtharmor_iconalign "3"
 seta hud_panel_healtharmor_baralign "3"
index 04902e07f8a64fee26a1dc990515730535a635e8..a0f26dbffd11fb459bd1c0ca7171f40eff3b3192 100644 (file)
@@ -109,6 +109,7 @@ seta hud_panel_healtharmor_bg_color_team ""
 seta hud_panel_healtharmor_bg_alpha ""
 seta hud_panel_healtharmor_bg_border ""
 seta hud_panel_healtharmor_bg_padding ""
+seta hud_panel_healtharmor_combined "0"
 seta hud_panel_healtharmor_flip "0"
 seta hud_panel_healtharmor_iconalign "3"
 seta hud_panel_healtharmor_baralign "3"
index 76214f49035e9abdeae7d30ca50966f2c213f5af..893ba950202996141280b6e302bd2fa4df50eb62 100644 (file)
@@ -109,6 +109,7 @@ seta hud_panel_healtharmor_bg_color_team ""
 seta hud_panel_healtharmor_bg_alpha ""
 seta hud_panel_healtharmor_bg_border ""
 seta hud_panel_healtharmor_bg_padding "0"
+seta hud_panel_healtharmor_combined "0"
 seta hud_panel_healtharmor_flip "0"
 seta hud_panel_healtharmor_iconalign "3"
 seta hud_panel_healtharmor_baralign "3"
index 722a316fd0c031ff37f58f42fda32f6d9a0d8b21..297d2af4fb669b80260f156517785d91fac573ce 100644 (file)
@@ -109,6 +109,7 @@ seta hud_panel_healtharmor_bg_color_team ""
 seta hud_panel_healtharmor_bg_alpha "0.600000"
 seta hud_panel_healtharmor_bg_border "-1"
 seta hud_panel_healtharmor_bg_padding "0"
+seta hud_panel_healtharmor_combined "0"
 seta hud_panel_healtharmor_flip "0"
 seta hud_panel_healtharmor_iconalign "1"
 seta hud_panel_healtharmor_baralign "1"
index 3138471bb798a603f2345e00d80046267efa3b00..ef3da2df102b5af6f590b9ab1b66a9083207e404 100644 (file)
@@ -109,6 +109,7 @@ seta hud_panel_healtharmor_bg_color_team ""
 seta hud_panel_healtharmor_bg_alpha ""
 seta hud_panel_healtharmor_bg_border ""
 seta hud_panel_healtharmor_bg_padding ""
+seta hud_panel_healtharmor_combined "0"
 seta hud_panel_healtharmor_flip "0"
 seta hud_panel_healtharmor_iconalign "3"
 seta hud_panel_healtharmor_baralign "3"
index 791653f270a920c139feeb8d5a8170269c449a76..5ae9a1aa8c52e652d5cb189f211ba1d53b61794b 100644 (file)
@@ -109,6 +109,7 @@ seta hud_panel_healtharmor_bg_color_team ""
 seta hud_panel_healtharmor_bg_alpha ""
 seta hud_panel_healtharmor_bg_border ""
 seta hud_panel_healtharmor_bg_padding ""
+seta hud_panel_healtharmor_combined "0"
 seta hud_panel_healtharmor_flip "0"
 seta hud_panel_healtharmor_iconalign "0"
 seta hud_panel_healtharmor_baralign "0"
index 3320b16620927c9840efeb86021f73ec1392484d..c36d451547ca21b5109590575793f149e11193b8 100644 (file)
@@ -230,6 +230,7 @@ float autocvar_hud_panel_engineinfo_framecounter_time;
 float autocvar_hud_panel_fg_alpha;
 bool autocvar_hud_panel_healtharmor;
 int autocvar_hud_panel_healtharmor_baralign;
+bool autocvar_hud_panel_healtharmor_combined;
 bool autocvar_hud_panel_healtharmor_flip;
 int autocvar_hud_panel_healtharmor_iconalign;
 int autocvar_hud_panel_healtharmor_maxarmor;
index 07166105e5f6f043d99d65ccb57e95da60275e35..853efd81da916273ab43e013673beafad9223dd7 100644 (file)
@@ -120,6 +120,7 @@ void HUD_Panel_ExportCfg(string cfgname)
                                        HUD_Write_PanelCvar("_progressbar_armor");
                                        HUD_Write_PanelCvar("_progressbar_gfx");
                                        HUD_Write_PanelCvar("_progressbar_gfx_smooth");
+                                       HUD_Write_PanelCvar("_combined");
                                        HUD_Write_PanelCvar("_text");
                                        break;
                                case HUD_PANEL_NOTIFY:
index 3b03979177da96edf15e5c4a3ee0ed35f04b0ee1..8f279f2aadc2e1e1c46db7d7118af4da94a75c12 100644 (file)
@@ -74,7 +74,7 @@ void HUD_HealthArmor()
 
     int maxhealth = autocvar_hud_panel_healtharmor_maxhealth;
     int maxarmor = autocvar_hud_panel_healtharmor_maxarmor;
-       if(autocvar_hud_panel_healtharmor == 2) // combined health and armor display
+       if(autocvar_hud_panel_healtharmor_combined) // combined health and armor display
        {
                vector v;
                v = healtharmor_maxdamage(health, armor, armorblockpercent, DEATH_WEAPON.m_id);
index c158ebabfca0309288fbc2f1537434b450bc2bba..ac305b83258638cd4352305a7071d338a5d85b3d 100644 (file)
@@ -11,6 +11,8 @@ void XonoticHUDHealthArmorDialog_fill(entity me)
 
        DIALOG_HUDPANEL_COMMON();
 
+       me.TR(me);
+               me.TD(me, 1, 4, e = makeXonoticCheckBox(0, "hud_panel_healtharmor_combined", _("Combine health and armor")));
        me.TR(me);
                me.TD(me, 1, 4, e = makeXonoticCheckBox(0, "hud_panel_healtharmor_progressbar", _("Enable status bar")));
        me.TR(me);
index 68ffe79ea56546b2139ddfe6a18b8f5ac213865a..495047c5fca1788ff6cb4e21b338fd0c8b0e9878 100644 (file)
@@ -6,7 +6,7 @@ CLASS(XonoticHUDHealthArmorDialog, XonoticRootDialog)
        ATTRIB(XonoticHUDHealthArmorDialog, title, string, _("Health/Armor Panel"))
        ATTRIB(XonoticHUDHealthArmorDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT)
        ATTRIB(XonoticHUDHealthArmorDialog, intendedWidth, float, 0.4)
-       ATTRIB(XonoticHUDHealthArmorDialog, rows, float, 15)
+       ATTRIB(XonoticHUDHealthArmorDialog, rows, float, 16)
        ATTRIB(XonoticHUDHealthArmorDialog, columns, float, 4)
        ATTRIB(XonoticHUDHealthArmorDialog, name, string, "HUDhealtharmor")
        ATTRIB(XonoticHUDHealthArmorDialog, requiresConnection, float, true)