diff options
author | rubidium <rubidium@openttd.org> | 2010-08-22 09:18:01 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2010-08-22 09:18:01 +0000 |
commit | 56a263070f3afb6dfea3bdc5113874f8db66b23a (patch) | |
tree | 77bac298035e5812105822e93d8772de2aa8f050 /src/date.cpp | |
parent | fba7ce392d753a1646919eebd7a277f87262e0e5 (diff) | |
download | openttd-56a263070f3afb6dfea3bdc5113874f8db66b23a.tar.xz |
(svn r20591) -Codechange: make sure _date_fract is set when SetDate is called. Some places wouldn't reset _date_fract correctly at all
Diffstat (limited to 'src/date.cpp')
-rw-r--r-- | src/date.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/date.cpp b/src/date.cpp index bdf4dd0fc..bc3c1d106 100644 --- a/src/date.cpp +++ b/src/date.cpp @@ -29,13 +29,15 @@ uint16 _tick_counter; ///< Ever incrementing (and sometimes wrapping) tick coun /** * Set the date. - * @param date New date + * @param date New date + * @param fract The number of ticks that have passed on this date. */ -void SetDate(Date date) +void SetDate(Date date, DateFract fract) { YearMonthDay ymd; _date = date; + _date_fract = fract; ConvertDateToYMD(date, &ymd); _cur_year = ymd.year; _cur_month = ymd.month; |