Jonathan G Rennison
828d2146eb
Merge branch 'master' into jgrpp
...
# Conflicts:
# CMakeLists.txt
# bin/ai/CMakeLists.txt
# bin/game/CMakeLists.txt
# src/ai/ai_info.cpp
# src/company_base.h
# src/economy.cpp
# src/game/game_info.cpp
# src/gfx_type.h
# src/linkgraph/linkgraph_gui.cpp
# src/palette.cpp
# src/palette_func.h
# src/saveload/saveload.h
# src/saveload/vehicle_sl.cpp
# src/ship_cmd.cpp
# src/train_cmd.cpp
# src/vehicle_base.h
# src/window.cpp
# src/window_func.h
2024-02-26 18:19:34 +00:00
Peter Nelson
912d7bd80e
Codechange: Give ColourShade values names instead of numbers.
2024-02-25 12:38:07 +00:00
Peter Nelson
ae3390fe48
Codechange: Add ColourShade enum.
2024-02-25 12:38:07 +00:00
Peter Nelson
0463d4c198
Codechange: Remove direct access to _colour_gradient.
...
Access is now through GetColourGradient, which ensures parameters are in range.
2024-02-25 12:38:07 +00:00
Jonathan G Rennison
090656bd7f
Adjust handling of year display in wallclock mode and company inauguration years
...
See: #657
2024-02-25 03:27:45 +00:00
Damian Laczak
2aa574a48f
Fix #10983 : [AdminPort] Correct order of messages
...
(cherry picked from commit 49c3215751
)
2024-02-19 23:11:00 +00:00
Jonathan G Rennison
a98a56669b
Merge branch 'master' into jgrpp
...
# Conflicts:
# regression/regression/result.txt
# src/autoreplace_cmd.cpp
# src/industry_gui.cpp
# src/landscape.cpp
# src/network/network_content.cpp
# src/newgrf_roadstop.cpp
# src/pathfinder/yapf/yapf_ship.cpp
# src/road_gui.cpp
# src/saveload/ai_sl.cpp
# src/saveload/saveload.h
# src/saveload/vehicle_sl.cpp
# src/station.cpp
# src/station_gui.cpp
# src/video/cocoa/cocoa_ogl.h
# src/video/sdl2_opengl_v.h
# src/video/video_driver.hpp
# src/video/win32_v.h
# src/widget_type.h
# src/widgets/dropdown.cpp
# src/widgets/dropdown_type.h
# src/window.cpp
2024-02-19 23:11:00 +00:00
Damian Laczak
49c3215751
Fix #10983 : [AdminPort] Correct order of messages
2024-02-18 15:11:00 +01:00
Jonathan G Rennison
838b166726
Merge branch 'master' into jgrpp
...
# Conflicts:
# src/cheat_gui.cpp
# src/command.cpp
# src/command_func.h
# src/company_base.h
# src/debug.cpp
# src/debug.h
# src/economy.cpp
# src/engine_type.h
# src/graph_gui.cpp
# src/misc_cmd.cpp
# src/misc_cmd.h
# src/network/core/os_abstraction.cpp
# src/openttd.cpp
# src/saveload/saveload.cpp
# src/saveload/saveload.h
# src/settings_type.h
# src/ship_cmd.cpp
# src/stdafx.h
# src/tests/bitmath_func.cpp
# src/town_cmd.cpp
# src/town_gui.cpp
2024-02-17 11:53:35 +00:00
Jonathan G Rennison
7ce06e22b8
Split date types into calendar and economy dates
...
See: 735abfe1
2024-02-13 21:34:09 +00:00
Loïc Guilloux
977aba73be
Change: Store running AI config inside Company ( #12003 )
2024-02-09 22:55:49 +01:00
Jonathan G Rennison
cfebbfac8c
Merge branch 'master' into jgrpp
...
# Conflicts:
# src/autoreplace_cmd.cpp
# src/company_base.h
# src/company_gui.cpp
# src/cpu.cpp
# src/debug.h
# src/group.h
# src/group_cmd.cpp
# src/house.h
# src/industry.h
# src/newgrf_house.cpp
# src/news_type.h
# src/openttd.cpp
# src/saveload/company_sl.cpp
# src/settings_type.h
# src/sl/oldloader_sl.cpp
# src/story.cpp
# src/table/town_land.h
# src/viewport.cpp
2024-02-09 18:50:49 +00:00
Jonathan G Rennison
cb13ee90ef
Fix: Second colour vehicle-type default liveries not being updated
...
When changing company default second colour
2024-02-04 07:14:39 +01:00
Jonathan G Rennison
736539280b
Fix second colour vehicle-type default liveries not being updated
...
When changing company default second colour
2024-02-03 23:11:49 +00:00
dP
897b59c158
Add: [GS] Allow to set max loan for each company separately ( #11224 )
2024-01-30 19:15:19 +01:00
merni-ns
5a88027a19
Feature: Infinite money mode ( #11902 )
2024-01-30 18:01:02 +00:00
Tyler Trahan
735abfe111
Codechange: Split dates and timers into Economy and Calendar time ( #10700 )
2024-01-22 09:04:34 -05:00
Peter Nelson
c0ab436077
Codechange: Store Colours in Colours type. ( #11625 )
...
This reduces casts, some magic numbers, and introduces a bit of type-safety.
2024-01-21 13:23:04 +00:00
Jonathan G Rennison
3d87cfeca5
Plans: Cache whether any plans are currently visible
2024-01-18 21:58:48 +00:00
Jonathan G Rennison
97e6f3062e
Adding of _t to (u)int types, and WChar to char32_t
...
See: eaae0bb5e
2024-01-07 17:20:41 +00:00
Jonathan G Rennison
f034714559
Use StringBuilder for GetString/GetStringWithArgs, as per upstream
...
Update dependent code as required
2024-01-05 21:12:54 +00:00
Jonathan G Rennison
7f6b1d6b94
Merge branch 'master' into jgrpp
...
# Conflicts:
# src/company_cmd.cpp
# src/company_func.h
# src/core/overflowsafe_type.hpp
# src/engine.cpp
# src/music/midifile.cpp
# src/network/network_command.cpp
# src/newgrf_debug_gui.cpp
# src/newgrf_roadstop.h
# src/newgrf_spritegroup.cpp
# src/os/macosx/crashlog_osx.cpp
# src/os/unix/crashlog_unix.cpp
# src/pathfinder/yapf/yapf_common.hpp
# src/road_gui.cpp
# src/saveload/engine_sl.cpp
# src/script/api/script_depotlist.cpp
# src/script/api/script_roadtypelist.cpp
# src/settings_gui.cpp
# src/settings_type.h
# src/strings.cpp
# src/table/settings/game_settings.ini
2024-01-05 13:37:52 +00:00
Peter Nelson
06050f7bb3
Fix: Pass townnameparts as parameter when testing townname based companyname. ( #11685 )
...
Length of returned string could vary and pass/fail the length check with a different
string than the final selection.
2024-01-04 23:10:54 +00:00
Jonathan G Rennison
ffff696b4e
Merge branch 'master' into jgrpp
...
# Conflicts:
# src/build_vehicle_gui.cpp
# src/cheat_gui.cpp
# src/console_cmds.cpp
# src/crashlog.cpp
# src/date_gui.cpp
# src/engine.cpp
# src/group_cmd.cpp
# src/landscape.cpp
# src/network/network_gui.cpp
# src/newgrf.cpp
# src/saveload/afterload.cpp
# src/script/api/script_date.cpp
# src/sl/oldloader_sl.cpp
# src/station_cmd.cpp
# src/station_cmd.h
# src/strings.cpp
# src/subsidy_gui.cpp
# src/survey.cpp
# src/timer/timer_game_calendar.cpp
# src/timer/timer_game_calendar.h
2023-12-29 14:46:53 +00:00
Peter Nelson
bfb4254226
Fix: Changing default livery did not propagate to group liveries.
...
#11614 attempted to address this but did not handle 2CC properly, and changes to the default livery were not handled.
2023-12-28 23:16:19 +00:00
Jonathan G Rennison
4689113553
Debug: De-duplicate formatting of hex dates for desync/random logging
2023-12-19 17:55:57 +00:00
Jonathan G Rennison
03e0ec8276
Strong typedef: Use strong typedefs for date, date tick, minutes types
...
Add delta types
Adjust/add type conversion functions
Add various utility methods on types
Remove the various minute macros
Fix some minute conversion inconsistencies
2023-12-19 02:39:54 +00:00
Jonathan G Rennison
c929f7075e
Merge branch 'master' into jgrpp
...
# Conflicts:
# cmake/SourceList.cmake
# src/build_vehicle_gui.cpp
# src/company_gui.cpp
# src/console_cmds.cpp
# src/depot_base.h
# src/elrail.cpp
# src/network/core/udp.cpp
# src/network/network_admin.cpp
# src/network/network_chat_gui.cpp
# src/network/network_gui.cpp
# src/network/network_server.cpp
# src/newgrf.cpp
# src/newgrf_engine.cpp
# src/newgrf_railtype.cpp
# src/newgrf_railtype.h
# src/newgrf_storage.h
# src/os/unix/crashlog_unix.cpp
# src/rail.h
# src/rail_cmd.cpp
# src/rail_gui.cpp
# src/road_cmd.cpp
# src/road_map.h
# src/saveload/labelmaps_sl.cpp
# src/settings_gui.cpp
# src/settings_type.h
# src/sl/oldloader_sl.cpp
# src/station_cmd.cpp
# src/station_gui.cpp
# src/table/settings/world_settings.ini
# src/tests/test_script_admin.cpp
# src/textfile_gui.cpp
# src/toolbar_gui.cpp
# src/train_cmd.cpp
# src/tunnelbridge_cmd.cpp
# src/vehicle_gui.cpp
# src/widget.cpp
# src/window.cpp
# src/window_gui.h
# src/window_type.h
2023-11-19 13:00:21 +00:00
Jonathan G Rennison
3436e0a781
Merge branch 'master' into jgrpp
...
# Conflicts:
# src/error.h
# src/error_gui.cpp
# src/linkgraph/linkgraph_gui.cpp
# src/misc_gui.cpp
# src/newgrf_gui.cpp
# src/news_gui.cpp
# src/rail_cmd.cpp
# src/saveload/gamelog_sl.cpp
# src/script/api/script_text.cpp
# src/script/script_instance.cpp
# src/statusbar_gui.cpp
# src/strings.cpp
# src/strings_func.h
# src/strings_internal.h
# src/table/settings/gui_settings.ini
# src/table/settings/linkgraph_settings.ini
# src/textbuf_gui.h
2023-11-09 01:55:23 +00:00
Peter Nelson
ab535c0a86
Codechange: Add base() method to StrongType to allow access to the base type without casting. ( #11445 )
...
This removes the ability to explicitly cast to the base type, but the requirement
to use .base() means the conversion is still explicit.
2023-11-06 20:29:35 +00:00
Jonathan G Rennison
a18f3274b4
Rename close window functions to match upstream
2023-09-15 21:17:25 +01:00
Jonathan G Rennison
3e3e083770
Merge branch 'master' into jgrpp
...
Hostile takeover feature
# Conflicts:
# src/company_base.h
# src/company_cmd.cpp
# src/company_gui.cpp
# src/economy.cpp
# src/script/api/script_event_types.cpp
2023-09-12 19:04:03 +01:00
PeterN
acd7d3c913
Codechange: Rename *Railtype* to *RailType* for consistency. ( #11287 )
2023-09-11 08:55:12 +00:00
Tyler Trahan
fca2b37726
Codechange: Move Ticks into their own class
2023-09-10 08:40:25 -04:00
PeterN
afc1ea8135
Codechange: Using alias and std::array for company expense storage. ( #11273 )
...
This simplifies passing yearly expenses to functions and use of std algorithms.
2023-09-09 13:15:53 +00:00
Loïc Guilloux
568eafe661
Fix #11179 , a979d9c
: Don't start more competitors than allowed ( #11185 )
...
(cherry picked from commit 02be6ab6ba
)
2023-09-01 18:47:46 +01:00
Patric Stout
07730584d7
Codechange: make explicit when a TileIndex is cast to its basetype ( #11190 )
...
This prevents people accidentially assigning a TileIndex to a Date
or any other type they shouldn't.
2023-08-15 18:12:05 +02:00
Loïc Guilloux
02be6ab6ba
Fix #11179 , a979d9c
: Don't start more competitors than allowed ( #11185 )
2023-08-11 22:30:01 +02:00
Loïc Guilloux
2ddc5d9cd6
Fix #11067 , ed83c4b
: Don't start competitors during map generation ( #11069 )
...
(cherry picked from commit a979d9cdda
)
2023-07-31 18:21:45 +01:00
Loïc Guilloux
a979d9cdda
Fix #11067 , ed83c4b
: Don't start competitors during map generation ( #11069 )
2023-07-29 12:31:33 +02:00
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
2023-07-19 19:30:14 +02:00
Jonathan G Rennison
371a555324
Disable picker tool in spectator mode
2023-06-17 17:00:49 +01:00
Rubidium
82b434b589
Codechange: rename function to better describe what it is doing
2023-06-12 09:12:11 +02:00
Patric Stout
3b1407d240
Feature: allow to do a hostile takeover of an AI company (in singleplayer) ( #10914 )
...
With the removal of the share-system, you could no longer make an
AI disappear in a single player game. At least, not without going
into the console.
2023-06-05 19:32:22 +02:00
Jonathan G Rennison
3a47b421b0
Merge branch 'master' into jgrpp
...
# Conflicts:
# src/company_cmd.cpp
# src/core/overflowsafe_type.hpp
# src/economy.cpp
# src/engine_base.h
# src/ground_vehicle.cpp
# src/group_gui.cpp
# src/industry_cmd.cpp
# src/industry_gui.cpp
# src/newgrf_commons.cpp
# src/newgrf_engine.cpp
# src/newgrf_industries.cpp
# src/newgrf_object.cpp
# src/newgrf_roadstop.cpp
# src/newgrf_station.cpp
# src/rail_gui.cpp
# src/road_cmd.h
# src/road_gui.cpp
# src/saveload/afterload.cpp
# src/script/api/script_log.cpp
# src/script/api/script_log.hpp
# src/settings_gui.cpp
# src/settingsgen/settingsgen.cpp
# src/station_cmd.cpp
# src/station_cmd.h
# src/station_gui.cpp
# src/strgen/strgen.cpp
# src/string_func.h
# src/string_type.h
# src/table/settings/network_private_settings.ini
# src/tests/math_func.cpp
# src/textfile_gui.cpp
# src/timetable_gui.cpp
# src/town_cmd.cpp
# src/vehicle.cpp
# src/waypoint_cmd.cpp
# src/waypoint_cmd.h
# src/widgets/dropdown.cpp
2023-06-03 19:16:57 +01:00
Jonathan G Rennison
bac8f032da
Re-add company shares
2023-05-30 18:57:42 +01:00
Jonathan G Rennison
02fe4af934
Merge branch 'master' into jgrpp
...
# Conflicts:
# .github/workflows/release-windows.yml
# src/company_base.h
# src/company_cmd.cpp
# src/company_gui.cpp
# src/console_cmds.cpp
# src/economy.cpp
# src/economy_cmd.h
# src/fios.h
# src/goal.cpp
# src/group_gui.cpp
# src/network/core/config.h
# src/network/network_admin.cpp
# src/newgrf_config.cpp
# src/os/windows/win32.cpp
# src/saveload/afterload.cpp
# src/saveload/company_sl.cpp
# src/saveload/saveload.cpp
# src/saveload/saveload_error.hpp
# src/settings_gui.cpp
# src/ship_cmd.cpp
# src/stdafx.h
# src/story.cpp
# src/story_base.h
# src/string.cpp
# src/table/settings/economy_settings.ini
# src/tests/CMakeLists.txt
# src/tests/math_func.cpp
2023-05-30 00:49:24 +01:00
Jonathan G Rennison
fd4d4d341d
Merge branch 'master' into jgrpp
...
# Conflicts:
# src/animated_tile.cpp
# src/cargopacket.h
# src/cheat_gui.cpp
# src/company_cmd.cpp
# src/company_gui.cpp
# src/date.cpp
# src/disaster_vehicle.cpp
# src/dock_gui.cpp
# src/economy.cpp
# src/engine.cpp
# src/error_gui.cpp
# src/fontcache/spritefontcache.cpp
# src/game/game_gui.cpp
# src/game/game_text.cpp
# src/gfx.cpp
# src/graph_gui.cpp
# src/highscore_gui.cpp
# src/industry_cmd.cpp
# src/lang/dutch.txt
# src/lang/english_AU.txt
# src/lang/english_US.txt
# src/lang/finnish.txt
# src/lang/french.txt
# src/lang/italian.txt
# src/lang/portuguese.txt
# src/lang/russian.txt
# src/lang/turkish.txt
# src/lang/vietnamese.txt
# src/main_gui.cpp
# src/misc_gui.cpp
# src/network/network_gui.cpp
# src/network/network_server.cpp
# src/newgrf.cpp
# src/newgrf.h
# src/newgrf_generic.cpp
# src/news_gui.cpp
# src/openttd.cpp
# src/os/unix/unix.cpp
# src/os/windows/font_win32.cpp
# src/os/windows/win32.cpp
# src/rail_gui.cpp
# src/road_gui.cpp
# src/saveload/afterload.cpp
# src/saveload/misc_sl.cpp
# src/saveload/oldloader_sl.cpp
# src/saveload/saveload.cpp
# src/saveload/saveload.h
# src/script/script_gui.cpp
# src/settings_table.cpp
# src/signs_gui.cpp
# src/smallmap_gui.cpp
# src/smallmap_gui.h
# src/spritecache.cpp
# src/spritecache.h
# src/spriteloader/grf.cpp
# src/station_cmd.cpp
# src/statusbar_gui.cpp
# src/stdafx.h
# src/strgen/strgen_base.cpp
# src/subsidy.cpp
# src/table/settings/difficulty_settings.ini
# src/texteff.cpp
# src/timetable_cmd.cpp
# src/timetable_gui.cpp
# src/toolbar_gui.cpp
# src/town_cmd.cpp
# src/town_gui.cpp
# src/townname.cpp
# src/vehicle.cpp
# src/waypoint_cmd.cpp
# src/widgets/dropdown.cpp
# src/window.cpp
2023-05-26 19:36:48 +01:00
Rubidium
63d9bb93b8
Codechange: migrate from C-style GetString to C++-style GetString
2023-05-21 21:17:12 +02:00
Rubidium
e33b2afd87
Codechange: pass (uint) money as Money for CmdGiveMoney
2023-05-06 21:26:13 +02:00