From 982e2b0a1f17322ac40fbd1815fdc3d5c1ff774b Mon Sep 17 00:00:00 2001
From: nehalmistry <>
Date: Fri, 21 Jun 2002 00:19:43 +0000
Subject: [PATCH] *** empty log message ***

---
 src/editor/editloop.cpp | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/src/editor/editloop.cpp b/src/editor/editloop.cpp
index 2998b43ba..00fdcf568 100644
--- a/src/editor/editloop.cpp
+++ b/src/editor/editloop.cpp
@@ -382,7 +382,11 @@ local void DrawTileIcons(void)
 */
 local void DrawUnitIcons(void)
 {
-    int x, y, i, j, percent;
+    int x;
+    int y;
+    int i;
+    int j;
+    int percent;
     char buf[256];
     Icon *icon;
 
@@ -545,7 +549,7 @@ local void DrawUnitIcons(void)
 	VideoDraw(MenuButtonGfx.Sprite, MBUTTON_RIGHT_ARROW, x + j - 20, y);
     }
 
-    percent = UnitIndex * 100 / MaxUnitIndex;
+    percent = UnitIndex * 100 / (MaxUnitIndex - 3);
     i = (percent * (j - 54)) / 100;
     VideoDraw(MenuButtonGfx.Sprite, MBUTTON_S_KNOB, x + 18 + i, y + 1);