summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorglx <glx@openttd.org>2007-11-23 04:17:41 +0000
committerglx <glx@openttd.org>2007-11-23 04:17:41 +0000
commitee81e00082cd777c0d89094b73ee43e1e7c10372 (patch)
treeac89c1c9e5c02962b4bb06b321a2236a9d6014d0
parent2ebf50e421c75eedf240b235871b2bb9534d6cf8 (diff)
downloadopenttd-ee81e00082cd777c0d89094b73ee43e1e7c10372.tar.xz
(svn r11499) -Fix (r11144): mul/div factor were wrong (off by two)
-rw-r--r--src/industry_cmd.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/industry_cmd.cpp b/src/industry_cmd.cpp
index e9fadbc86..a2556f3eb 100644
--- a/src/industry_cmd.cpp
+++ b/src/industry_cmd.cpp
@@ -2018,9 +2018,9 @@ static void ChangeIndustryProduction(Industry *i, bool monthly)
case 0x3: closeit = true; break; // The industry announces imminent closure, and is physically removed from the map next month.
case 0x4: standard = true; break; // Do the standard random production change as if this industry was a primary one.
case 0x5: case 0x6: case 0x7: // Divide production by 4, 8, 16
- case 0x8: div = res - 0x5; break; // Divide production by 32
+ case 0x8: div = res - 0x3; break; // Divide production by 32
case 0x9: case 0xA: case 0xB: // Multiply production by 4, 8, 16
- case 0xC: mul = res - 0x9; break; // Multiply production by 32
+ case 0xC: mul = res - 0x7; break; // Multiply production by 32
}
}
}