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
commit74cf54910a7a2a3a61803a22f850fb50a487d75f (patch)
treeac89c1c9e5c02962b4bb06b321a2236a9d6014d0
parent0fce8dbf1f54b922b3dc8adf8c96f57221451752 (diff)
downloadopenttd-74cf54910a7a2a3a61803a22f850fb50a487d75f.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
}
}
}