summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/industry_cmd.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/industry_cmd.cpp b/src/industry_cmd.cpp
index 967c1d385..13774b41a 100644
--- a/src/industry_cmd.cpp
+++ b/src/industry_cmd.cpp
@@ -2143,9 +2143,13 @@ static void ChangeIndustryProduction(Industry *i, bool monthly)
}
}
+ /* Increase or Decreasing the production level if needed */
if (increment != 0) {
- i->prod_level = ClampU(i->prod_level + increment, 4, 0x80);
- if (i->prod_level == 4) closeit = true;
+ if !(increment < 0 && i->prod_level == 4) {
+ closeit = true;
+ } else {
+ i->prod_level = ClampU(i->prod_level + increment, 4, 0x80);
+ }
}
/* Close if needed and allowed */