summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortruebrain <truebrain@openttd.org>2009-01-13 18:04:12 +0000
committertruebrain <truebrain@openttd.org>2009-01-13 18:04:12 +0000
commite1f64922c5acb3f2173108ca81b656266bb8b651 (patch)
treec3e8ffaa86ef7bed2576eb09b24713ef8f61aaf1
parent4780c732241b78be16df0cd493c79931c97344aa (diff)
downloadopenttd-e1f64922c5acb3f2173108ca81b656266bb8b651.tar.xz
(svn r15066) -Change: start_date is now in days, instead of in months (Yexo)
-rw-r--r--src/ai/ai.hpp12
-rw-r--r--src/company_cmd.cpp4
2 files changed, 7 insertions, 9 deletions
diff --git a/src/ai/ai.hpp b/src/ai/ai.hpp
index 6658d1de5..f53a1c9fd 100644
--- a/src/ai/ai.hpp
+++ b/src/ai/ai.hpp
@@ -21,12 +21,12 @@ public:
* The default months AIs start after eachother.
*/
enum StartNext {
- START_NEXT_EASY = 48,
- START_NEXT_MEDIUM = 24,
- START_NEXT_HARD = 12,
+ START_NEXT_EASY = 1461,
+ START_NEXT_MEDIUM = 730,
+ START_NEXT_HARD = 365,
START_NEXT_MIN = 0,
- START_NEXT_MAX = 120,
- START_NEXT_DEVIATION = 2,
+ START_NEXT_MAX = 3600,
+ START_NEXT_DEVIATION = 60,
};
/**
@@ -101,7 +101,7 @@ public:
static void Load(CompanyID company, int version);
/**
- * Get the number of months before the next AI should start.
+ * Get the number of days before the next AI should start.
*/
static int GetStartNextTime();
diff --git a/src/company_cmd.cpp b/src/company_cmd.cpp
index 6526de585..89f73414e 100644
--- a/src/company_cmd.cpp
+++ b/src/company_cmd.cpp
@@ -487,8 +487,6 @@ static void MaybeStartNewCompany()
* Works fine for Multiplayer and Singleplayer */
DoCommandP(0, 1, 0, CMD_COMPANY_CTRL);
}
-
- _next_competitor_start = AI::GetStartNextTime() * 30 * DAY_TICKS;
}
void InitializeCompanies()
@@ -508,7 +506,7 @@ void OnTick_Companies()
}
if (_next_competitor_start == 0) {
- _next_competitor_start = AI::GetStartNextTime() * 30 * DAY_TICKS;
+ _next_competitor_start = AI::GetStartNextTime() * DAY_TICKS;
}
if (AI::CanStartNew() && _game_mode != GM_MENU && --_next_competitor_start == 0) {