Commit Graph

56 Commits (88670a230f82bc1d43e29b550b71c8878b62c470)

Author SHA1 Message Date
Jonathan G Rennison 88670a230f Merge branch 'master' into jgrpp
# Conflicts:
#	src/articulated_vehicles.cpp
#	src/articulated_vehicles.h
#	src/base_media_base.h
#	src/base_media_func.h
#	src/build_vehicle_gui.cpp
#	src/dock_gui.cpp
#	src/main_gui.cpp
#	src/music_gui.cpp
#	src/network/network_chat_gui.cpp
#	src/network/network_content.cpp
#	src/newgrf.cpp
#	src/newgrf_roadstop.cpp
#	src/os/windows/string_uniscribe.h
#	src/os/windows/win32.cpp
#	src/rail_gui.cpp
#	src/road.cpp
#	src/road_gui.cpp
#	src/settings.cpp
#	src/settings_gui.cpp
#	src/smallmap_gui.cpp
#	src/strings.cpp
#	src/terraform_gui.cpp
#	src/tests/test_script_admin.cpp
#	src/tests/test_window_desc.cpp
#	src/timer/timer_game_calendar.h
#	src/vehicle.cpp
#	src/vehicle_base.h
#	src/viewport.cpp
#	src/widget_type.h
#	src/window.cpp
#	src/window_gui.h
6 months ago
Tyler Trahan 701a61c9af Codechange: Delete date_type.h 9 months ago
Tyler Trahan 77173a6a10 Codechange: Move date consts and functions to CalendarTime and TimerGameCalendar classes 9 months ago
Tyler Trahan fca2b37726 Codechange: Move Ticks into their own class 9 months ago
Patric Stout 299570b2c1
Codechange: make TimerGameCalendar Date and Year types strongly typed (#10761) 10 months ago
Tyler Trahan 6190f48df0
Codechange: Add a DateToYear function instead of dividing each time (#11173) 10 months ago
Rubidium eaae0bb5e7 Codechange: automatic adding of _t to (u)int types, and WChar to char32_t
for i in `find src -type f|grep -v 3rdparty/fmt|grep -v 3rdparty/catch2|grep -v 3rdparty/opengl|grep -v stdafx.h`; do sed 's/uint16& /uint16 \&/g;s/int8\([ >*),;[]\)/int8_t\1/g;s/int16\([ >*),;[]\)/int16_t\1/g;s/int32\([ >*),;[]\)/int32_t\1/g;s/int64\([ >*),;[]\)/int64_t\1/g;s/ uint32(/ uint32_t(/g;s/_uint8_t/_uint8/;s/Uint8_t/Uint8/;s/ft_int64_t/ft_int64/g;s/uint64$/uint64_t/;s/WChar/char32_t/g;s/char32_t char32_t/char32_t WChar/' -i $i; done
11 months ago
Patric Stout 97138acc8a
Codechange: make date-related variables constexpr (#11129)
This hints the compiler even more to result math-related questions
compile-time.
11 months ago
Jonathan G Rennison 37b8b59c85 Merge branch 'master' into jgrpp
# Conflicts:
#	src/date_type.h
#	src/linkgraph/linkgraphjob.cpp
#	src/linkgraph/linkgraphschedule.cpp
#	src/saveload/saveload.h
#	src/table/settings/linkgraph_settings.ini
1 year ago
Jonathan G Rennison 5dd99fb046 Add setting for milliseconds per game tick mode 1 year ago
Tyler Trahan 98d809c33b
Codechange: Don't use macros for DAYS_TILL and friends (#10746) 1 year ago
Tyler Trahan 6501f84b4a
Codechange: Move calendar date functions inside TimerGameCalendar (#10753) 1 year ago
Tyler Trahan 930f0a16d8 Codechange: Define Date/Year/Month/Day within TimerGameCalendar class 1 year ago
Patric Stout 7aa2b9ab0a
Codechange: move all date-related variables inside the timer (#10706) 1 year ago
Tyler Trahan 646a7e625b
Change: Use seconds for Linkgraph update settings (#10610) 1 year ago
Tyler Trahan 8e04cba0c3
Change: Make tick length 27 milliseconds (#10607)
This makes a month last about 60 seconds, allowing the use of real-time units in game.

Co-authored-by: Niels Martin Hansen <nielsm@indvikleren.dk>
1 year ago
Tyler Trahan fb0549ea59 Feature: Configurable subsidy duration
(cherry picked from commit d09210e1c6)
3 years ago
Tyler Trahan d09210e1c6 Feature: Configurable subsidy duration 3 years ago
Jonathan G Rennison f5e9805b10 Store time display settings both in savegame and client, add setting 4 years ago
Jonathan G Rennison 7960db35f2 Merge branch 'master' into jgrpp
# Conflicts:
#	config.lib
#	projects/openttd_vs140.vcxproj
#	projects/openttd_vs140.vcxproj.filters
#	projects/openttd_vs141.vcxproj
#	projects/openttd_vs141.vcxproj.filters
#	projects/openttd_vs142.vcxproj
#	projects/openttd_vs142.vcxproj.filters
#	src/aircraft_cmd.cpp
#	src/base_station_base.h
#	src/core/pool_type.hpp
#	src/disaster_vehicle.cpp
#	src/economy.cpp
#	src/engine.cpp
#	src/group.h
#	src/group_cmd.cpp
#	src/group_gui.cpp
#	src/lang/english.txt
#	src/lang/german.txt
#	src/linkgraph/linkgraph_gui.cpp
#	src/network/network_command.cpp
#	src/network/network_server.cpp
#	src/openttd.cpp
#	src/order_cmd.cpp
#	src/road_cmd.cpp
#	src/saveload/afterload.cpp
#	src/saveload/cargopacket_sl.cpp
#	src/saveload/linkgraph_sl.cpp
#	src/saveload/order_sl.cpp
#	src/saveload/station_sl.cpp
#	src/saveload/town_sl.cpp
#	src/saveload/vehicle_sl.cpp
#	src/screenshot.cpp
#	src/screenshot.h
#	src/settings_gui.cpp
#	src/settings_type.h
#	src/smallmap_gui.cpp
#	src/station.cpp
#	src/station_cmd.cpp
#	src/table/settings.ini
#	src/toolbar_gui.cpp
#	src/town_cmd.cpp
#	src/train.h
#	src/train_cmd.cpp
#	src/train_gui.cpp
#	src/vehicle.cpp
#	src/vehicle_base.h
#	src/vehiclelist.cpp
#	src/window_type.h
4 years ago
Niels Martin Hansen 2fd871e2af Feature: Configurable game ending year
Functionally reverts 683b65ee1
4 years ago
Jonathan G Rennison cbdd9f84d8 Merge branch 'master' into jgrpp
# Conflicts:
#	src/console_gui.cpp
#	src/lang/korean.txt
#	src/video/sdl2_v.cpp
#	src/video/sdl2_v.h
#	src/window.cpp
#	src/window_gui.h
5 years ago
S. D. Cloudt 13cc8a0cee Cleanup: Removed SVN headers 5 years ago
Jonathan G Rennison ee169c4455 Fix numerical/signed overflow when using high day lengths
Bug reported at day length = 125
7 years ago
Jonathan G Rennison 375b069f82 Replace day length scaled tick macros with global variables.
This is to avoid needing to expensively re-calculate them all the time.
Instead update them by incrementing.
8 years ago
Jonathan G Rennison 26fa77c5ee Run animations at the normal rate regardless of day length factor. 8 years ago
Jonathan G Rennison 29809f2001 Time in minutes is no longer scaled by day length.
Time in minutes now based on the existing date ticks * the day length,
plus the tick skip counter, instead of just the date ticks.
Change the format of the {DATE_WALLCLOCK_*} string params
to use date ticks scaled by the day length, as above.
Update status bar clock.
9 years ago
patch-import 79138de1b9 Import departure boards patch 9 years ago
rubidium 0d9a8b07ec (svn r25260) -Codechange: occasionally clear dead links and compress link graphs (fonsinchen) 11 years ago
rubidium be4f85766c (svn r25260) -Codechange: occasionally clear dead links and compress link graphs (fonsinchen) 11 years ago
planetmaker 122c4622f5 (svn r22548) -Codechange: Name also the magic number for the lumber mill's tree cutting action (FeyFre) 13 years ago
planetmaker e5a88a1077 (svn r22548) -Codechange: Name also the magic number for the lumber mill's tree cutting action (FeyFre) 13 years ago
frosch 62b6d0eb0e (svn r22482) -Codechange: Add some contants for the number of ticks between certain cyclical tasks. 13 years ago
frosch 474b4799e8 (svn r22482) -Codechange: Add some contants for the number of ticks between certain cyclical tasks. 13 years ago
rubidium f09a74a996 (svn r19812) -Codechange: give some unnamed enums a name or, in case they consisted of unrelated values use static const (u)int 14 years ago
rubidium 398418b8fa (svn r19812) -Codechange: give some unnamed enums a name or, in case they consisted of unrelated values use static const (u)int 14 years ago
rubidium b15fb68503 (svn r18585) -Codechange: replace some magic numbers by constants 15 years ago
rubidium abb601f682 (svn r18585) -Codechange: replace some magic numbers by constants 15 years ago
rubidium bd9c679873 (svn r18292) -Codechange: add a command to set the start date of a timetable. Based on work by PhilSophus. 15 years ago
rubidium a951c505bf (svn r18292) -Codechange: add a command to set the start date of a timetable. Based on work by PhilSophus. 15 years ago
rubidium 371a220960 (svn r18291) -Codechange: rework the calculation of the 'days till year' macro a bit so it can be properly reused and add a MAX_DAY 15 years ago
rubidium 1a8c203d6e (svn r18291) -Codechange: rework the calculation of the 'days till year' macro a bit so it can be properly reused and add a MAX_DAY 15 years ago
rubidium 2e506b04aa (svn r18204) -Codechange: introduce a type for Ticks and use it; furthermore document some related variables/functions 15 years ago
rubidium 37056b564c (svn r18204) -Codechange: introduce a type for Ticks and use it; furthermore document some related variables/functions 15 years ago
rubidium 99d46e0ad7 (svn r17248) -Fix: add GPL license notice where appropriate 15 years ago
rubidium 7fbc33dae1 (svn r17248) -Fix: add GPL license notice where appropriate 15 years ago
smatz ca45774160 (svn r15077) -Codechange: enumify DAYS_IN_YEAR and DAYS_IN_LEAP_YEAR
-Change: when computing daily running cost, divide by 365 (instead of 364). Since r12134, the rounding errors don't need this correction anymore
16 years ago
smatz e00cf92f47 (svn r15077) -Codechange: enumify DAYS_IN_YEAR and DAYS_IN_LEAP_YEAR
-Change: when computing daily running cost, divide by 365 (instead of 364). Since r12134, the rounding errors don't need this correction anymore
16 years ago
rubidium f16427fbe0 (svn r14823) -Document: some variables/structs (Alberth) 16 years ago
rubidium 702c372744 (svn r14823) -Document: some variables/structs (Alberth) 16 years ago