X-Git-Url: https://git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fclient%2Fhud%2Fpanel%2Fammo.qc;h=b4a7b6040a92cd5f980253d8a4f51858c5df2662;hb=acc08b9655874164549bc2600f78c6edbc3c084a;hp=95ceced82c74d7ca6a39adc2084de9e950c85a2c;hpb=4b615d6ea3ee6794ea9368c782393c66ef55c170;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/client/hud/panel/ammo.qc b/qcsrc/client/hud/panel/ammo.qc index 95ceced82..b4a7b6040 100644 --- a/qcsrc/client/hud/panel/ammo.qc +++ b/qcsrc/client/hud/panel/ammo.qc @@ -1,15 +1,26 @@ #include "ammo.qh" -#include -#include -#include +#include +#include #include -#include -#include #include +#include // Ammo (#1) +void HUD_Ammo_Export(int fh) +{ + // allow saving cvars that aesthetically change the panel into hud skin files + HUD_Write_Cvar("hud_panel_ammo_onlycurrent"); + HUD_Write_Cvar("hud_panel_ammo_noncurrent_alpha"); + HUD_Write_Cvar("hud_panel_ammo_noncurrent_scale"); + HUD_Write_Cvar("hud_panel_ammo_iconalign"); + HUD_Write_Cvar("hud_panel_ammo_progressbar"); + HUD_Write_Cvar("hud_panel_ammo_progressbar_name"); + HUD_Write_Cvar("hud_panel_ammo_progressbar_xoffset"); + HUD_Write_Cvar("hud_panel_ammo_text"); +} + void DrawNadeProgressBar(vector myPos, vector mySize, float progress, vector color) { HUD_Panel_DrawProgressBar( @@ -104,7 +115,7 @@ void HUD_Ammo() { if((!autocvar_hud_panel_ammo) || (spectatee_status == -1)) return; - if(STAT(HEALTH) < 1 && autocvar_hud_panel_ammo_hide_ondeath) + if(STAT(HEALTH) <= 0 && autocvar_hud_panel_ammo_hide_ondeath) return; }