From c8397d2474c7da2a5c26124e48b039fc2d4973cd Mon Sep 17 00:00:00 2001 From: Marco Cawthorne Date: Tue, 7 Feb 2023 09:08:00 -0800 Subject: [PATCH] Client: clamp the armor subpic size to 1.0 (fixes graphical artifacts in TFC) --- src/client/hud.qc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/client/hud.qc b/src/client/hud.qc index 3f4879b..2c37af5 100644 --- a/src/client/hud.qc +++ b/src/client/hud.qc @@ -211,7 +211,7 @@ HUD_DrawArmor(void) ); if (pl.armor > 0) { - float perc = (pl.armor / 100); + float perc = bound(0, (pl.armor / 100), 1.0); drawsubpic( pos + [-80,-9] + [0, 40 * (1.0-perc)], [40, 40 * perc],