[nexuiz-commits] r7446 - trunk/data/qcsrc/client

DONOTREPLY at icculus.org DONOTREPLY at icculus.org
Sun Aug 16 11:09:07 EDT 2009


Author: fruitiex
Date: 2009-08-16 11:09:07 -0400 (Sun, 16 Aug 2009)
New Revision: 7446

Modified:
   trunk/data/qcsrc/client/sbar.qc
Log:
small cleanup to prevent alpha values greater than 1...


Modified: trunk/data/qcsrc/client/sbar.qc
===================================================================
--- trunk/data/qcsrc/client/sbar.qc	2009-08-16 13:40:34 UTC (rev 7445)
+++ trunk/data/qcsrc/client/sbar.qc	2009-08-16 15:09:07 UTC (rev 7446)
@@ -2454,11 +2454,14 @@
 			x = armor;
 			if (x > 0)
 			{
-				drawpic(armor_pos + '78 -4.5 0', "gfx/hud/sb_armor", '32 32 0', '1 1 1', (x+10)/55 * sbar_alpha_fg, DRAWFLAG_NORMAL);
-				if (x > 45)
+				if (x > 45) {
+					drawpic(armor_pos + '78 -4.5 0', "gfx/hud/sb_armor", '32 32 0', '1 1 1', sbar_alpha_fg, DRAWFLAG_NORMAL);
 					Sbar_DrawXNum_Colored(armor_pos, x, 24, sbar_alpha_fg);
-				else
+				}
+				else {
+					drawpic(armor_pos + '78 -4.5 0', "gfx/hud/sb_armor", '32 32 0', '1 1 1', (x+10)/55 * sbar_alpha_fg, DRAWFLAG_NORMAL);
 					Sbar_DrawXNum_Colored(armor_pos, x, 24, (x+10)/55 * sbar_alpha_fg);
+				}
 			}
 
 			// health



More information about the nexuiz-commits mailing list