summaryrefslogtreecommitdiff
path: root/openttd.h
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2006-08-14 14:21:15 +0000
committerrubidium <rubidium@openttd.org>2006-08-14 14:21:15 +0000
commit9fc837ad85e06b4f99014990537cf91b95474a3d (patch)
treece66f3f78e1bc27ddba6fa055772ec9eb5492f84 /openttd.h
parente6e42cd5f3122a1b0dbceb31cc35eb8a9ca23f8b (diff)
downloadopenttd-9fc837ad85e06b4f99014990537cf91b95474a3d.tar.xz
(svn r5887) -Cleanup: move date related functions, defines and variables to date.[ch]
-Cleanup: fix whitespace related coding style issues in date.[ch] -Cleanup: make original comments doxygen compatible and remove/change outdated comments
Diffstat (limited to 'openttd.h')
-rw-r--r--openttd.h20
1 files changed, 3 insertions, 17 deletions
diff --git a/openttd.h b/openttd.h
index 18fa5b449..b7287dd38 100644
--- a/openttd.h
+++ b/openttd.h
@@ -30,23 +30,6 @@ typedef struct SortStruct {
byte owner;
} SortStruct;
-typedef struct YearMonthDay {
- int year, month, day;
-} YearMonthDay;
-
-/* --- 1 Day is 74 ticks ---
-* The game's internal structure is dictated by ticks. The date counter (date_fract) is an integer of
-* uint16 type, so it can have a max value of 65536. Every tick this variable (date_fract) is
-* increased by 885. When it overflows, the new day loop is called.
-* * this that means 1 day is : 65536 / 885 = 74 ticks
-* * 1 tick is approximately 27ms.
-* * 1 day is thus about 2 seconds (74*27 = 1998) on a machine that can run OpenTTD normally
-*/
-#define DAY_TICKS 74
-#define MAX_YEAR_BEGIN_REAL 1920
-#define MAX_YEAR_END_REAL 2090
-#define MAX_YEAR_END 170
-
#include "map.h"
#include "slope.h"
@@ -78,6 +61,9 @@ typedef uint16 UnitID; ///< All unitnumber stuff is of this type (or anyway, s
typedef uint32 WindowNumber;
typedef byte WindowClass;
+typedef uint8 Year;
+typedef uint32 Date;
+
enum GameModes {
GM_MENU,