Commit Graph

458 Commits (f5747bf753258574c1bd40aa205b5c250bc30408)

Author SHA1 Message Date
Jonathan G Rennison 4bf4862674 Add AI/game script DoCommand calls to command log 5 years ago
Jonathan G Rennison ba34ec7ade Merge branch 'master' into jgrpp
Replace build and refit, and group collapse implementations
Fix template creation build and refit

# Conflicts:
#	Makefile.bundle.in
#	config.lib
#	src/animated_tile.cpp
#	src/blitter/32bpp_anim.hpp
#	src/blitter/32bpp_base.hpp
#	src/blitter/8bpp_base.hpp
#	src/blitter/null.hpp
#	src/build_vehicle_gui.cpp
#	src/command.cpp
#	src/command_func.h
#	src/console_gui.cpp
#	src/core/smallstack_type.hpp
#	src/date.cpp
#	src/debug.cpp
#	src/genworld_gui.cpp
#	src/ground_vehicle.hpp
#	src/group_gui.cpp
#	src/lang/korean.txt
#	src/linkgraph/linkgraph_gui.h
#	src/main_gui.cpp
#	src/misc_gui.cpp
#	src/network/core/game.h
#	src/network/core/packet.cpp
#	src/network/core/udp.cpp
#	src/network/core/udp.h
#	src/network/network_content.cpp
#	src/network/network_type.h
#	src/network/network_udp.cpp
#	src/newgrf_house.h
#	src/openttd.cpp
#	src/order_cmd.cpp
#	src/order_gui.cpp
#	src/os/unix/crashlog_unix.cpp
#	src/os/windows/crashlog_win.cpp
#	src/osk_gui.cpp
#	src/pathfinder/opf/opf_ship.cpp
#	src/rail_cmd.cpp
#	src/rail_gui.cpp
#	src/saveload/saveload.cpp
#	src/settings.cpp
#	src/settings_gui.cpp
#	src/smallmap_gui.h
#	src/station_base.h
#	src/station_cmd.cpp
#	src/table/gameopt_settings.ini
#	src/table/newgrf_debug_data.h
#	src/table/settings.ini
#	src/timetable_gui.cpp
#	src/toolbar_gui.cpp
#	src/train_gui.cpp
#	src/vehicle.cpp
#	src/vehicle_gui.cpp
#	src/vehiclelist.cpp
#	src/viewport.cpp
#	src/widgets/dropdown.cpp
#	src/window_gui.h
5 years ago
Henry Wilson bfd79e59dc Codechange: Replace SmallVector::Clear() with std::vector::clear() 5 years ago
Patric Stout e3c639a09f Remove: ENABLE_NETWORK switch
This switch has been a pain for years. Often disabling broke
compilation, as no developer compiles OpenTTD without, neither do
any of our official binaries.

Additionaly, it has grown so hugely in our codebase, that it
clearly shows that the current solution was a poor one. 350+
instances of "#ifdef ENABLE_NETWORK" were in the code, of which
only ~30 in the networking code itself. The rest were all around
the code to do the right thing, from GUI to NewGRF.

A more proper solution would be to stub all the functions, and
make sure the rest of the code can simply assume network is
available. This was also partially done, and most variables were
correct if networking was disabled. Despite that, often the #ifdefs
were still used.

With the recent removal of DOS, there is also no platform anymore
which we support where networking isn't working out-of-the-box.

All in all, it is time to remove the ENABLE_NETWORK switch. No
replacement is planned, but if you feel we really need this option,
we welcome any Pull Request which implements this in a way that
doesn't crawl through the code like this diff shows we used to.
5 years ago
Jonathan G Rennison ac54a2c28c Log type/length of text param in DoCommand/DoCommandP scope info 5 years ago
Jonathan G Rennison 1340392497 Verify length of binary data in CmdBuildVehicle and CmdAddPlanLine 5 years ago
Jonathan G Rennison b0284c8d9e Improve type and length safety of commands taking binary data 5 years ago
Jonathan G Rennison 2fdcc52321 Merge branch 'save_ext' into jgrpp
# Conflicts:
#	Makefile.src.in
#	findversion.sh
#	projects/determineversion.vbs
#	src/lang/dutch.txt
#	src/lang/korean.txt
#	src/network/network.cpp
#	src/network/network_client.cpp
#	src/rail.cpp
#	src/rail_cmd.cpp
#	src/saveload/afterload.cpp
#	src/ship_cmd.cpp
#	src/toolbar_gui.cpp
#	src/vehicle.cpp
5 years ago
Peter Nelson b1e40b6b56 Fix #7151: Hang when concurrently starting AIs in multiplayer, or with shift pressed. 5 years ago
Jonathan G Rennison ddf31702a2 Merge branch 'master' into jgrpp
# Conflicts:
#	src/group_gui.cpp
#	src/lang/english.txt
#	src/saveload/saveload.cpp
#	src/widgets/group_widget.h
5 years ago
PeterN 23960d0f2c Feature: Group liveries, and livery window usability enhancements. (#7108)
* Change: Replace checkbox in livery selection window with Default option in drop down selection.

This reduces clutter in the UI and allows for primary/secondary colours to independently follow the default scheme if desired.

* Feature: Add vehicle group liveries.
5 years ago
Jonathan G Rennison 10320747a9 Allow purchasing a region of tile at once, by dragging 6 years ago
Jonathan G Rennison 989577d40c Add support for adding a third error line to the error GUI
Add support for a second error string ID to CommandCost
6 years ago
Jonathan G Rennison e735c1a51a Merge branch 'master' into jgrpp
# Conflicts:
#	src/aircraft_cmd.cpp
#	src/autoreplace_cmd.cpp
#	src/pathfinder/follow_track.hpp
#	src/pathfinder/yapf/yapf_rail.cpp
#	src/saveload/afterload.cpp
#	src/saveload/saveload.cpp
#	src/script/api/ai/ai_station.hpp.sq
#	src/script/api/game/game_station.hpp.sq
#	src/script/api/script_station.hpp
#	src/track_func.h
#	src/vehicle_base.h
6 years ago
Charles Pigott f5b1115039 Doc: Lots and lots of doxymentation fixes 6 years ago
Jonathan G Rennison ee00a28717 Merge branch 'template_train_replacement' into jgrpp
# Conflicts:
#	src/saveload/extended_ver_sl.cpp
6 years ago
Jonathan G Rennison c4f5c8e789 TBTR: Add option to replace only old vehicles 6 years ago
Jonathan G Rennison cff61bac96 Merge branch 'progsig-sx' into jgrpp
# Conflicts:
#	src/command.cpp
6 years ago
Jonathan G Rennison e01ea3e629 Change progsig command type from landscape to other management 6 years ago
Jonathan G Rennison d8b9e2953e Merge branch 'enhanced_viewport_overlay' into jgrpp
# Conflicts:
#	src/command.cpp
#	src/saveload/extended_ver_sl.cpp
6 years ago
keldorkatarn 98da7019d6 Plans: Make it possible to give plans a name.
(cherry picked from commit d9b553f130a6eda36e2eea217785f829d3d8624e)
6 years ago
Jonathan G Rennison 90f89770c2 Set CMD_NO_TEST flag for plan commands
(cherry picked from commit 8709fdade3)
6 years ago
Jonathan G Rennison 940314a3c7 Use std::string for CommandContainer text instead of giant static buffer
Use move semantics for CommandContainer instance where feasible
6 years ago
Jonathan G Rennison 8709fdade3 Set CMD_NO_TEST flag for plan commands 6 years ago
Jonathan G Rennison 9e1e074c2b Update existing assertions to log tile information where suitable 6 years ago
Jonathan G Rennison cecbf257bc Merge branch 'save_ext' into template_train_replacement
# Conflicts:
#	src/saveload/saveload.cpp
#	src/vehicle_gui.cpp
6 years ago
Jonathan G Rennison 1fe0bb76b9 Merge branches 'crashlog_improvements', 'save_ext', 'version_utils' into jgrpp 6 years ago
Jonathan G Rennison f42cc19aad Merge branch 'cpp-11' into crashlog_improvements
# Conflicts:
#	Makefile.src.in
#	src/crashlog.cpp
#	src/crashlog.h
6 years ago
Pavel Stupnikov 8e4bce58ea Feature: GS methods to scroll viewport for players (#6745) 6 years ago
innocenat 0b8f0e64ec Scheduled Dispatch feature
Code is tested and run well on small-ish train network. Not tested extensively.
7 years ago
Jonathan G Rennison 4979309094 TBTR: Fix build and refit of template trains. 7 years ago
Jonathan G Rennison b8328ad21f Merge branch 'tracerestrict-sx' into jgrpp
# Conflicts:
#	src/command.cpp
#	src/group_gui.cpp
#	src/lang/english.txt
#	src/saveload/extended_ver_sl.cpp
#	src/settings_gui.cpp
#	src/tracerestrict.cpp
#	src/tracerestrict.h
#	src/tracerestrict_gui.cpp
#	src/vehicle_gui.cpp
#	src/vehicle_gui_base.h
#	src/vehiclelist.cpp
#	src/window_type.h
7 years ago
Jonathan G Rennison 6417fb16c3 Initial implementation of trace restrict slots 7 years ago
Jonathan G Rennison 2fbeb29277 Merge branch 'crashlog_improvements' into jgrpp
# Conflicts:
#	src/misc.cpp
#	src/openttd.cpp
7 years ago
Jonathan G Rennison 349ddd90b7 Maintain a circular buffer of recent commands, add to crashlog.
Add console command to dump command log.
Increase max crashlog size.
7 years ago
Jonathan G Rennison fba4268127 Build and refit vehicle test no longer needs to match exec command. 7 years ago
Jonathan G Rennison 8e6569c11f Include tick skip counter in all desync debug output.
Change message format to make field identification easier.
Update desync message reader to support tick skip counter.
8 years ago
Jonathan G Rennison 4c5173b6bf Merge branch 'auto_timetables-sx' into jgrpp
# Conflicts:
#	src/lang/english.txt
#	src/saveload/afterload.cpp
#	src/saveload/extended_ver_sl.cpp
#	src/settings_gui.cpp
#	src/settings_type.h
#	src/table/company_settings.ini
#	src/vehicle.cpp
8 years ago
Jonathan G Rennison d59252d15b Timetable auto separation is now per vehicle, with a company default.
Remove global on-off setting.
Add button to timetable GUI.
Add company setting to control default for new vehicles.

Fix automate, start date, change time and autofill buttons
being shown enabled for other companies' vehicles.
8 years ago
keldorkatarn 5cc56d6ad9 Make 32 instead of 16 rail types possible. by using one free bit of m1 in the map array.
(cherry picked from commit b44843800880cdc186f5183301ee0f42afbb5f84)

Also set non-rail type M3 bits to 0 where applicable.
Change savegame versioning to SLXI format.
8 years ago
Jonathan G Rennison ca9f6411cc Implement adding a vehicle list to a new group. 8 years ago
Jonathan G Rennison c0cc72ad96 Implement change timetable waiting time for all stations.
Loosely based on http://www.tt-forums.net/viewtopic.php?f=32&t=50274
8 years ago
Jonathan G Rennison 4722c81e88 Merge branch 'crashlog_improvements' into jgrpp 8 years ago
Jonathan G Rennison 0062881a46 Avoid using malloc in scope guard logger.
Use a temporary object with its own buffer, which lives on the stack.

Reformat SCOPE_INFO_FMT to not be all on one line.
Other minor reformatting.
8 years ago
Jonathan G Rennison 5dba89c783 Merge branch 'crashlog_improvements' into jgrpp
# Conflicts:
#	source.list
#	src/openttd.cpp
#	src/stdafx.h
#	src/vehicle.cpp
8 years ago
Jonathan G Rennison ae6e43c5fa Initial uses of scope guard logging. 8 years ago
Jonathan G Rennison 48e4c35fdc Add support for verbose asserts.
Use for test/exec DoCommand mismatches.
8 years ago
Jonathan G Rennison 0779c7b7a9 Merge branch 'template_train_replacement-sx' into jgrpp
# Conflicts:
#	src/build_vehicle_gui.cpp
#	src/saveload/afterload.cpp
8 years ago
Jonathan G Rennison 5850bcf699 TBTR: Fix crash and issues when using a no longer available engine type.
Show error messages when cloning a vehicle to a template
or virtual vehicle fails.
Handle failed clones gracefully.
Bypass engine availability check when doing a template edit action.
Show correct error message if template replacement fails for
a non-money reason.
8 years ago
Jonathan G Rennison 580b2f7584 Merge branch 'template_train_replacement-sx' into jgrpp
Remove a duplicated declaration.

# Conflicts:
#	projects/openttd_vs100.vcxproj
#	projects/openttd_vs100.vcxproj.filters
#	projects/openttd_vs140.vcxproj
#	projects/openttd_vs140.vcxproj.filters
#	projects/openttd_vs80.vcproj
#	projects/openttd_vs90.vcproj
#	source.list
#	src/group_gui.cpp
#	src/lang/english.txt
#	src/network/network_command.cpp
#	src/saveload/extended_ver_sl.cpp
#	src/saveload/extended_ver_sl.h
#	src/saveload/saveload.cpp
#	src/train_cmd.cpp
#	src/vehicle.cpp
#	src/vehicle_gui.cpp
#	src/vehicle_gui_base.h
#	src/window_type.h
8 years ago