Commit Graph

788 Commits

Author SHA1 Message Date
Jonathan G Rennison
9521e7ef2b Merge branch 'master' into jgrpp
# Conflicts:
#	src/elrail.cpp
#	src/ground_vehicle.hpp
#	src/landscape.cpp
#	src/saveload/afterload.cpp
#	src/saveload/saveload.h
#	src/tile_cmd.h
#	src/town_cmd.cpp
#	src/tunnelbridge_cmd.cpp
2023-04-12 19:34:11 +01:00
Rubidium
e8af8daa68 Codechange: pass "ground vehicle" to GetTileSlopeZ since for tunnel/bridges there are two states
Previously it checked the position in non-driving direction to "guess" whether
a ground vehicle was using the function, so on tunnels/bridges it could either
return the Z of the (virtual) ground compared to the Z of the path the vehicle
would take.
2023-04-09 19:00:26 +02:00
Jonathan G Rennison
48d602962f Road stops: Add inferred one way road state to var 50/roadstop_misc_info 2023-03-15 19:44:26 +00:00
Jonathan G Rennison
983790ec7a Remove unused town argument from GetTownRoadType 2023-03-05 21:28:24 +00:00
Jonathan G Rennison
4ec6a99dd8 Add GetTileTrackStatus wrapper for when red signals part is not needed 2023-03-04 02:01:40 +00:00
Jonathan G Rennison
ae7c86c49d Merge branch 'master' into jgrpp
# Conflicts:
#	.github/workflows/release-linux.yml
#	.github/workflows/release-macos.yml
#	src/industry_cmd.cpp
#	src/industry_cmd.h
#	src/network/core/http_curl.cpp
#	src/network/core/tcp_http.cpp
#	src/network/core/tcp_http.h
#	src/network/network_content.h
#	src/script/api/script_goal.cpp
#	src/script/api/script_industry.cpp
#	src/script/api/script_league.cpp
#	src/script/api/script_story_page.cpp
#	src/script/api/script_town.cpp
#	src/train.h
#	src/train_cmd.cpp
2023-03-04 01:17:27 +00:00
SamuXarick
b52b29b1a4 Change: Avoid crashing to the side of a train
When a road vehicle is already running on a multi level crossing, and a train shows up ahead, don't make the road vehicle crash on the side of the train.
2023-02-22 20:09:02 +01:00
Jonathan G Rennison
f7d62a1767 Add road/tram type flag to disallow collisions with trains 2023-02-19 18:05:11 +00:00
Jonathan G Rennison
663a3969a0 Add road/tram type flag to disallow tunnels 2023-02-19 15:21:35 +00:00
Jonathan G Rennison
3497d0dcdb Add road/tram type properties to set road vehicle collision mode 2023-02-19 14:30:21 +00:00
Jonathan G Rennison
483e3172af Merge branch 'master' into jgrpp
# Conflicts:
#	src/core/strong_typedef_type.hpp
#	src/gfx.cpp
#	src/group_cmd.cpp
#	src/industry_cmd.cpp
#	src/map_func.h
#	src/newgrf_debug_gui.cpp
#	src/order_cmd.cpp
#	src/pathfinder/follow_track.hpp
#	src/rail_cmd.cpp
#	src/road_cmd.cpp
#	src/road_gui.cpp
#	src/saveload/saveload.cpp
#	src/screenshot.cpp
#	src/smallmap_gui.cpp
#	src/station_cmd.cpp
#	src/strings.cpp
#	src/tile_type.h
#	src/timetable_gui.cpp
#	src/town_cmd.cpp
#	src/train_cmd.cpp
#	src/viewport.cpp
2023-02-10 17:19:35 +00:00
rubidium42
6ba55e663e Codechange: do not hide variables with other variables 2023-01-29 07:21:34 +01:00
Rubidium
fe2bcd2a58 Codechange: migrate size related functions to Map structure 2023-01-21 17:11:40 +01:00
Jonathan G Rennison
5b490b243d Merge branch 'master' into jgrpp
# Conflicts:
#	src/industry_cmd.cpp
#	src/landscape.cpp
#	src/object_cmd.cpp
#	src/rail_cmd.cpp
#	src/script/api/script_tile.cpp
#	src/table/settings/difficulty_settings.ini
#	src/table/settings/world_settings.ini
#	src/terraform_cmd.cpp
#	src/tilearea_type.h
#	src/tree_cmd.cpp
#	src/tree_cmd.h
#	src/tree_gui.cpp
#	src/water_cmd.cpp
2023-01-14 16:49:17 +00:00
Rubidium
b35c791d05 Codechange: use smart pointers when cloning iterators 2023-01-13 21:09:40 +01:00
Jonathan G Rennison
64c210f770 Merge branch 'master' into jgrpp
# Conflicts:
#	src/build_vehicle_gui.cpp
#	src/engine.cpp
#	src/engine_func.h
#	src/group_gui.cpp
#	src/lang/english.txt
#	src/newgrf.cpp
#	src/saveload/oldloader_sl.cpp
#	src/timetable_cmd.cpp
#	src/timetable_cmd.h
#	src/timetable_gui.cpp
2022-12-28 01:46:29 +00:00
Francis Herne
6caed5f15e Add: Slope-aware and roadtype-specific one-way sprites. (#10282) 2022-12-26 15:06:21 -05:00
Jonathan G Rennison
8af4ac8a4c GRF: Add road stops variable for road info of nearby plain road tile
See: #464
2022-12-24 18:54:28 +00:00
Jonathan G Rennison
3435e74c0c Merge branch 'master' into jgrpp
# Conflicts:
#	.github/workflows/ci-build.yml
#	.github/workflows/release.yml
#	CMakeLists.txt
#	os/macosx/Info.plist.in
#	src/fileio.cpp
#	src/landscape.cpp
#	src/league_cmd.h
#	src/saveload/ai_sl.cpp
#	src/saveload/game_sl.cpp
#	src/saveload/league_sl.cpp
#	src/saveload/saveload.cpp
2022-12-17 23:19:23 +00:00
Loïc Guilloux
c50fabb574 Fix #10208: allow to use specific underlay for road/tram tunnels (#10233) 2022-12-17 09:01:47 -05:00
Tyler Trahan
c719ba560e Fix 03cc0d6: Mark level crossings dirty when removing road from them, not from bridges (#10138) 2022-11-05 14:46:19 -04:00
Jonathan G Rennison
4b08874583 Only show edge level crossing overlays even when safer crossings is off 2022-11-03 00:57:47 +00:00
Tyler Trahan
c19abebf8d Feature: Multi-track level crossings (#9931) 2022-11-01 16:51:23 -04:00
Michael Lutz
8e6ed8d5e9 Fix db98cedb: Swap the tile parameter validation around as only the first TileIndex is automatically validated. 2022-10-17 07:54:58 +01:00
Tyler Trahan
db98cedb7e Fix #9883: Show cost/income float over end tile of rail or road construction 2022-10-16 14:15:31 +02:00
Jonathan G Rennison
846cd7e228 Add setting to limit length of continuous inclined roads built by towns
Default to max 4 tiles
2022-10-10 18:21:42 +01:00
Jonathan G Rennison
143230d8f2 Allow changing road vehicle driving side when all road vehicles in depots 2022-09-11 11:51:32 +01:00
Jonathan G Rennison
10b415bf10 Level crossings: Clarify adjacent blocked crossing track status handler
Avoid unnecessary adjacent tile checks if crossing is not blocked
2022-06-23 21:16:00 +01:00
Jonathan G Rennison
e9f6559d36 Merge branch 'pr-384' into jgrpp 2022-04-29 17:13:45 +01:00
Andreas Schmitt
114bed4549 Fix z-check for flat road foundations 2022-04-29 15:31:23 +02:00
Jonathan G Rennison
ad0dc6dc87 Add road stops flag to disable drawing catenary 2022-04-15 11:47:57 +01:00
Jonathan G Rennison
34af4844d1 Merge branch 'master' into jgrpp 2022-04-02 14:16:32 +01:00
Michael Lutz
8d54f76539 Fix #9837, 46bd2f1c: Road build with wrong half-tile ends. 2022-03-20 12:56:03 +01:00
Patric Stout
68ec2a7877 Fix: removing long roads doesn't prioritize refusal of local authority over other errors (#9831) 2022-03-11 16:18:09 +01:00
J0anJosep
d9a37c915f Cleanup #9725: Replace cmd_helper related functions and remove cmd_helper.h. 2022-02-02 21:30:15 +01:00
Jonathan G Rennison
70a65ac1c0 Road waypoints no longer block road inferred one-way state interpolation 2022-01-29 13:31:15 +00:00
Jonathan G Rennison
ad9c85ad3c Fix crash when changing one-way state of road waypoints 2022-01-29 13:31:15 +00:00
Jonathan G Rennison
c3c55db02b Implement road ground types for road waypoints 2022-01-26 22:15:17 +00:00
Jonathan G Rennison
b4fc0b4dc5 Initial implementation of road waypoints 2022-01-26 21:46:36 +00:00
Michael Lutz
2e39637db2 Codechange: Don't use a global for the 'not enough cash' message. 2021-12-16 22:28:32 +01:00
Michael Lutz
c6d7b98808 Codechange: Un-bitstuff landscape commands. 2021-12-16 22:28:32 +01:00
Michael Lutz
46bd2f1ced Codechange: Un-bitstuff remaining transport infrastructure commands. 2021-12-16 22:28:32 +01:00
Michael Lutz
55170ae703 Codechange: Un-bitstuff rail commands. 2021-12-16 22:28:32 +01:00
Michael Lutz
6fe445e6c0 Codechange: Un-bitstuff station/depot/waypoint commands. 2021-12-16 22:28:32 +01:00
Michael Lutz
e740c24eb7 Codechange: Template DoCommand to automagically reflect the parameters of the command proc.
When finished, this will allow each command handler to take individually
different parameters, obliviating the need for bit-packing.
2021-12-16 22:28:32 +01:00
Michael Lutz
7048e1522f Codechange: Move flags in CommandProc in front of the command arguments. 2021-12-16 22:28:32 +01:00
Michael Lutz
33ca4f2b99 Codechange: Let the compile generate the master command table out of templated command traits.
This is using a non-intrusive type-traits like templated system, which
allows compile-time validation that the command table and the command
enum match up.
2021-12-16 22:28:32 +01:00
Michael Lutz
b6933a2ebd Codechange: Move command arguments to the back of the DoCommand function call. 2021-12-16 22:28:32 +01:00
Jonathan G Rennison
5349003ec4 Add assert checks to road type infra total changes 2021-12-07 02:30:08 +00:00
Jonathan G Rennison
4ccbb11440 Only show level crossing overlay sprites on outsides of multi-track crossings
When using both adjacent crossings and safer crossings
2021-11-20 01:42:54 +00:00