Commit Graph

64 Commits (305062018918425feaad19330e31e65887320cf2)

Author SHA1 Message Date
Jonathan G Rennison 3050620189 Merge branch 'master' into jgrpp
# Conflicts:
#	src/autoreplace_cmd.cpp
#	src/build_vehicle_gui.cpp
#	src/cargotype.cpp
#	src/economy.cpp
#	src/engine_gui.cpp
#	src/industry_cmd.cpp
#	src/industry_gui.cpp
#	src/linkgraph/linkgraph_gui.h
#	src/linkgraph/refresh.cpp
#	src/linkgraph/refresh.h
#	src/newgrf.cpp
#	src/newgrf_airporttiles.h
#	src/newgrf_roadstop.cpp
#	src/newgrf_station.cpp
#	src/newgrf_station.h
#	src/order_base.h
#	src/order_cmd.cpp
#	src/order_func.h
#	src/order_gui.cpp
#	src/pathfinder/pathfinder_type.h
#	src/saveload/afterload.cpp
#	src/subsidy_base.h
#	src/vehicle_cmd.cpp
#	src/vehicle_gui.cpp
#	src/vehicle_gui_base.h
5 months ago
Peter Nelson 400ae65ff2 Codechange: Redefine some cargo-related values in terms of CargoID instead of CargoType.
Values used as special filter types are now defined as offsets from NUM_CARGO instead of confusingly reusing CARGO_NO_REFIT/CARGO_AUTO_REFIT types.
5 months ago
Jonathan G Rennison 97e6f3062e Adding of _t to (u)int types, and WChar to char32_t
See: eaae0bb5e
5 months ago
Jonathan G Rennison 25ed7c2b53 Merge branch 'master' into jgrpp
# Conflicts:
#	src/music.cpp
#	src/script/api/script_company.cpp
#	src/script/api/script_event_types.cpp
#	src/script/api/script_group.cpp
#	src/script/api/script_object.cpp
#	src/script/api/script_road.cpp
1 year ago
Rubidium 8d443d1379 Add: company mode enforcement checks to functions with command or company access
Command functions are those that call ScriptObject::Command, and functions
with company access are any that call ScriptObject::GetCompany. This is a bit
over-protective, but having the check everywhere makes it easier to validate
that no check is missing automatically instead of by review.
1 year ago
Jonathan G Rennison faa77e2605 Merge branch 'master' into jgrpp
# Conflicts:
#	src/script/api/script_company.cpp
#	src/script/api/script_date.cpp
#	src/script/api/script_date.hpp
#	src/script/api/script_gamesettings.cpp
#	src/script/api/script_order.hpp
#	src/script/api/script_town.cpp
#	src/script/api/script_window.cpp
1 year ago
glx22 777b4d0987 Codechange: Use SQInteger for generic numbers in script_order 1 year ago
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
1 year ago
SamuXarick 3df9321a65 Fix: Some Script::IsValidVehicle checks need to be complemented with IsPrimaryVehicle
Add: [Script] ScriptVehicle.IsPrimaryVehicle
1 year ago
Jonathan G Rennison 1bfd96c7f2 Merge branch 'master' into jgrpp
# Conflicts:
#	src/3rdparty/fmt/core.h
#	src/command_type.h
#	src/console_cmds.cpp
#	src/core/overflowsafe_type.hpp
#	src/landscape.cpp
#	src/network/network.cpp
#	src/newgrf_object.h
#	src/object_cmd.cpp
#	src/order_gui.cpp
#	src/saveload/vehicle_sl.cpp
#	src/script/api/script_industrytype.cpp
#	src/script/api/script_object.hpp
#	src/script/api/script_town.cpp
#	src/table/object_land.h
#	src/timetable_cmd.cpp
#	src/tree_cmd.cpp
#	src/vehicle_gui.cpp
#	src/window.cpp
1 year ago
Rubidium 90f1768006 Codechange: add non-nullptr asserts in cases where it should never be nullptr
Though where similar calls are checked for nullptr as in those instances of
the use of that function it can actually return nullptr. In other words, write
down the assumption that the function never returns nullptr in an assert.
1 year ago
Jonathan G Rennison 1518c2fa1e Merge branch 'master' into jgrpp
# Conflicts:
#	src/depot_type.h
#	src/lang/german.txt
#	src/order_gui.cpp
#	src/pathfinder/yapf/yapf_rail.cpp
#	src/script/api/script_window.hpp.in
#	src/settings_table.cpp
#	src/train_cmd.cpp
2 years ago
Nicolas Chappe a9a21e784d Codechange: Always set the ODATFB_NEAREST_DEPOT flag for 'any depot' orders 2 years ago
Jonathan G Rennison 91af0c82d3 Adjust CmdModifyOrder p2 bit allocation 2 years ago
Jonathan G Rennison e5a421b65a Merge branch 'master' into jgrpp
# Conflicts:
#	src/economy.cpp
#	src/linkgraph/refresh.cpp
#	src/order_cmd.cpp
#	src/saveload/vehicle_sl.cpp
#	src/station.cpp
#	src/station_base.h
#	src/timetable_cmd.cpp
#	src/timetable_gui.cpp
#	src/vehicle.cpp
#	src/vehicle_base.h
#	src/vehicle_cmd.cpp
2 years ago
Niels Martin Hansen e68bf58989 Codechange: Use anonymous union for vehicle orders/old orders list 2 years ago
Michael Lutz 211c630cbe Codechange: Un-bitstuff order commands. 3 years ago
Michael Lutz 6691ee3b96 Codechange: Template script command calls. 3 years ago
Jonathan G Rennison 0b0d154788 Merge branch 'master' into jgrpp-beta
# Conflicts:
#	.github/workflows/ci-build.yml
#	src/lang/german.txt
#	src/lang/romanian.txt
#	src/lang/slovak.txt
#	src/lang/turkish.txt
#	src/network/core/address.cpp
#	src/network/core/tcp.h
#	src/network/core/udp.cpp
#	src/network/network.cpp
#	src/network/network_client.cpp
#	src/network/network_server.cpp
#	src/network/network_server.h
#	src/network/network_udp.cpp
#	src/openttd.cpp
#	src/saveload/newgrf_sl.cpp
#	src/tree_cmd.cpp
#	src/video/video_driver.hpp
#	src/window.cpp
#	src/window_gui.h
3 years ago
rubidium42 55a11710a6 Codechange: convert printf DEBUG statements to fmt Debug statements 3 years ago
glx22 38c97e1492 Codechange: Replace TILE_AREA_LOOP with range-based for loops 3 years ago
Jonathan G Rennison f11dcb8478 Fix crash if AI attempts to set order flags of invalid vehicle's order
Fixes: 4c8b358f
3 years ago
Jonathan G Rennison e1aca1ab34 Extend Order::flags to 16 bits, fixes conditional order target field size
Adjust order packing and CmdInsertOrder

See: #198
4 years ago
Jonathan G Rennison 6e17f9bf5d Use p3 for order indices which don't fit into p1
Fix insert/modify order overflowing p1
Don't use text field for change timetable
4 years ago
Jonathan G Rennison d210bc4d14 Merge branch 'master' into jgrpp
# Conflicts:
#	src/lang/korean.txt
#	src/saveload/afterload.cpp

Recalculate docking tile cache due to 57553cd8
4 years ago
SamuXarick 4d4005d8b7 Fix #8039: [AI/GS] SetOrderFlags and GetOrderDestination didn't work for oil rigs 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 d71a7c21da Fix #7593: Crash in ScriptOrder::GetOrderDistance in VT_AIR mode
Null pointer dereference occurred when either origin_tile or dest_tile
were waypoint tiles.
5 years ago
Jonathan G Rennison d3e0c3787f Merge branch 'master' into jgrpp-nrt
Merge trunk multiple docks implementation

# Conflicts:
#	docs/landscape_grid.html
#	src/order_cmd.cpp
#	src/pathfinder/npf/npf.cpp
#	src/pathfinder/yapf/yapf_ship.cpp
#	src/rail_cmd.cpp
#	src/saveload/afterload.cpp
#	src/saveload/oldloader_sl.cpp
#	src/saveload/station_sl.cpp
#	src/script/api/script_order.cpp
#	src/ship_cmd.cpp
#	src/station.cpp
#	src/station_base.h
#	src/station_cmd.cpp
#	src/tunnelbridge_cmd.cpp
5 years ago
peter1138 f538179878 Feature: Multi-tile docks and docking points. 5 years ago
Jonathan G Rennison bdcafb38cc Fix ScriptOrder::GetOrderDistance in VT_AIR mode on waypoint tiles 5 years ago
Jonathan G Rennison 674732cd68 Merge: Codechange: Use null pointer literal instead of the NULL macro 5 years ago
Henry Wilson 7c8e7c6b6e Codechange: Use null pointer literal instead of the NULL macro 5 years ago
Jonathan G Rennison 4c8b358ffe Add game setting to allow only non-stop orders for ground vehicles 5 years ago
Jonathan G Rennison 0e7519f33e Merge branch 'more_cond_orders-sx' into jgrpp
# Conflicts:
#	config.lib
#	projects/openttd_vs100.vcxproj
#	projects/openttd_vs100.vcxproj.filters
#	projects/openttd_vs80.vcproj
#	projects/openttd_vs90.vcproj
#	src/order_gui.cpp
#	src/order_type.h
#	src/saveload/afterload.cpp
#	src/saveload/extended_ver_sl.cpp
6 years ago
Eddi-z 13056aedbc Add: Conditional order for max. reliability (patch by Cirdan, #6360) (#7017) 6 years ago
keldorkatarn 1d3cf59d8a Allow building multiple docks per station.
(cherry picked from commit 0110c4a35d383e0be2cbb53cbe9cbe6784abb3e9)

# Conflicts:
#	src/station_cmd.cpp
7 years ago
rubidium 2be4215f43 (svn r26482) -Codechange: add an include that allows us to undefine/redefine "unsafe" functions to prevent them from being used, and thus having to care about certain aspects of their return values 10 years ago
rubidium 0463dbdc9e (svn r26482) -Codechange: add an include that allows us to undefine/redefine "unsafe" functions to prevent them from being used, and thus having to care about certain aspects of their return values 10 years ago
frosch 0bedd475e3 (svn r26148) -Fix [FS#5824] (r25735): Script API failed for vehicles with only implicit orders. 11 years ago
frosch 2e79fd9c40 (svn r26148) -Fix [FS#5824] (r25735): Script API failed for vehicles with only implicit orders. 11 years ago
rubidium e28dc02403 (svn r25612) -Fix [FS#5648]: [AI] Don't return ERR_UNKNOWN when trying to move an order to its current location 11 years ago
rubidium 6e12838376 (svn r25612) -Fix [FS#5648]: [AI] Don't return ERR_UNKNOWN when trying to move an order to its current location 11 years ago
michi_cc d372fb3b8e (svn r24353) -Fix [FS#5215] (r23506): [NoAI] A TileIndex isn't a station id, so don't use it as one. 12 years ago
michi_cc ef394916c9 (svn r24353) -Fix [FS#5215] (r23506): [NoAI] A TileIndex isn't a station id, so don't use it as one. 12 years ago
rubidium 3b7d290f3e (svn r24008) -Cleanup/doc: try not to mention (No)AI in script APIs 12 years ago
rubidium 22637f139f (svn r24008) -Cleanup/doc: try not to mention (No)AI in script APIs 12 years ago
rubidium ea113816c0 (svn r24006) -Fix [FS#5088]: AI used in names in API for GSOrder 12 years ago
rubidium e6a828def1 (svn r24006) -Fix [FS#5088]: AI used in names in API for GSOrder 12 years ago