+#include "healtharmor.qh"
+
+#include <common/deathtypes/all.qh>
+
/** Health/armor (#3) */
void HUD_HealthArmor()
{
if(hud != HUD_NORMAL) return;
if(spectatee_status == -1) return;
- health = getstati(STAT_HEALTH);
+ health = STAT(HEALTH);
if(health <= 0)
{
prev_health = -1;
return;
}
- armor = getstati(STAT_ARMOR);
+ armor = STAT(ARMOR);
// code to check for spectatee_status changes is in Ent_ClientData()
// prev_p_health and prev_health can be set to -1 there
pos = panel_pos;
mySize = panel_size;
+ if (autocvar_hud_panel_healtharmor_dynamichud)
+ HUD_Scale_Enable();
+ else
+ HUD_Scale_Disable();
HUD_Panel_DrawBg(1);
if(panel_bg_padding)
{
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);