summaryrefslogtreecommitdiff
path: root/src/industry.h
diff options
context:
space:
mode:
authoralberth <alberth@openttd.org>2010-11-13 15:07:34 +0000
committeralberth <alberth@openttd.org>2010-11-13 15:07:34 +0000
commit3211ab301e32ee65454f08c68268d9f13c5bf212 (patch)
treeb62c5da23257130e45f209c0b148a6e13cf81a45 /src/industry.h
parente861487bcb050a74058ca8c2723541c029089dd2 (diff)
downloadopenttd-3211ab301e32ee65454f08c68268d9f13c5bf212.tar.xz
(svn r21168) -Feature: Use desired industry counts rather than relative probability to decide which industry to build.
Diffstat (limited to 'src/industry.h')
-rw-r--r--src/industry.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/industry.h b/src/industry.h
index 1c1637946..9ff0e5403 100644
--- a/src/industry.h
+++ b/src/industry.h
@@ -146,6 +146,7 @@ void ReleaseDisastersTargetingIndustry(IndustryID);
/** Data for managing the number of industries of a single industry type. */
struct IndustryTypeBuildData {
uint32 probability; ///< Relative probability of building this industry.
+ uint16 target_count; ///< Desired number of industries of this type.
void GetIndustryTypeData(IndustryType it);
};
@@ -156,6 +157,7 @@ struct IndustryTypeBuildData {
struct IndustryBuildData {
IndustryTypeBuildData builddata[NUM_INDUSTRYTYPES]; ///< Industry build data for every industry type.
+ void SetupTargetCount();
void TryBuildNewIndustry();
};