Commit Graph

91 Commits (17c054a650e913b328946212ff7f118ae059b77b)

Author SHA1 Message Date
Jonathan G Rennison 97baff6fd8 Add client desync log to server desync log output 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 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
peter1138 07de9d6c3f Codechange: Use override keyword in networking classes. 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 940314a3c7 Use std::string for CommandContainer text instead of giant static buffer
Use move semantics for CommandContainer instance where feasible
6 years ago
rubidium bebf2291db (svn r26056) -Fix: a number of possibly uninitialised variables 11 years ago
rubidium 2e54c8fdfa (svn r26056) -Fix: a number of possibly uninitialised variables 11 years ago
planetmaker f00d9976f9 (svn r24900) -Fix [FS#5389]: Comments with typos (most fixes supplied by Eagle_rainbow) 12 years ago
planetmaker c24374f99c (svn r24900) -Fix [FS#5389]: Comments with typos (most fixes supplied by Eagle_rainbow) 12 years ago
alberth 19adc87262 (svn r24776) -Doc: Typo fixes, additions, and additional dots collected from various sources (including Eagle_rainbow, MinchinWeb) 12 years ago
alberth 732e073261 (svn r24776) -Doc: Typo fixes, additions, and additional dots collected from various sources (including Eagle_rainbow, MinchinWeb) 12 years ago
rubidium 3d605f6488 (svn r23595) -Codechange: add comma after last enum to get a more uniform coding style 13 years ago
rubidium df16ebd730 (svn r23595) -Codechange: add comma after last enum to get a more uniform coding style 13 years ago
rubidium ee93be2e3f (svn r22403) -Document: some more network/core code 13 years ago
rubidium 99ec3a044a (svn r22403) -Document: some more network/core code 13 years ago
rubidium 8e39557a2e (svn r22400) -Codechange: replace some defines in the tcp/game code so doxygen can create better documentation 13 years ago
rubidium 2e572b98de (svn r22400) -Codechange: replace some defines in the tcp/game code so doxygen can create better documentation 13 years ago
rubidium 347ec4d713 (svn r22370) -Codechange/fix: keep better accounting of the order in which clients joined:
* Clients can't be starved from joining the game
 * Clients will see the amount of clients actually waiting in front of them, instead of the amount of waiting clients in total
13 years ago
rubidium ce91f6b45e (svn r22370) -Codechange/fix: keep better accounting of the order in which clients joined:
* Clients can't be starved from joining the game
 * Clients will see the amount of clients actually waiting in front of them, instead of the amount of waiting clients in total
13 years ago
rubidium b469b1dc51 (svn r21429) -Fix [FS#3771]: the server didn't check for the paused state when allowing to execute commands 14 years ago
rubidium 0c23b0b3a4 (svn r21429) -Fix [FS#3771]: the server didn't check for the paused state when allowing to execute commands 14 years ago
rubidium 5a40992e84 (svn r21392) -Change: prepare the network protocol for getting the file size later in the download process 14 years ago
rubidium 97434f0e06 (svn r21392) -Change: prepare the network protocol for getting the file size later in the download process 14 years ago
rubidium 4c76d8eaf6 (svn r21361) -Change: make sure the client is listening, or rather receiving, our frames 14 years ago
rubidium 31c8ab0ed8 (svn r21361) -Change: make sure the client is listening, or rather receiving, our frames 14 years ago
rubidium c7066d00af (svn r21358) -Codechange: make some network function names conform to coding style 14 years ago
rubidium b6c2216749 (svn r21358) -Codechange: make some network function names conform to coding style 14 years ago
rubidium d7eafddc18 (svn r21254) -Change: show a different "lag" message when a client is lagging because of connection trouble or lagging because the client is just slow 14 years ago
rubidium 6d09f4a3cb (svn r21254) -Change: show a different "lag" message when a client is lagging because of connection trouble or lagging because the client is just slow 14 years ago
rubidium 242110b8cb (svn r21030) -Codechange: move ClientStatus into the network server socket class 14 years ago
rubidium f24c91c487 (svn r21030) -Codechange: move ClientStatus into the network server socket class 14 years ago
rubidium 9012b54fa2 (svn r21029) -Codechange: split the map downloading packet + 3-state enum into 3 separate packets 14 years ago
rubidium 2cd67a51ac (svn r21029) -Codechange: split the map downloading packet + 3-state enum into 3 separate packets 14 years ago
rubidium 7c6b360e01 (svn r21025) -Codechange: document PacketGameType's enums and reshuffle them slightly to make the whole more readable and easier to understand 14 years ago
rubidium 3317f1c01e (svn r21025) -Codechange: document PacketGameType's enums and reshuffle them slightly to make the whole more readable and easier to understand 14 years ago
rubidium 6012a9074c (svn r20993) -Codechange: some shuffling of game protocol packet description so they're documented in the "same" place as UDP, content and admin packets (dihedral) 14 years ago
rubidium d71f590ed6 (svn r20993) -Codechange: some shuffling of game protocol packet description so they're documented in the "same" place as UDP, content and admin packets (dihedral) 14 years ago
rubidium a0f7099a7d (svn r20937) -Codechange: move some variables from client/server to server only 14 years ago
rubidium c9cbab14ea (svn r20937) -Codechange: move some variables from client/server to server only 14 years ago
rubidium 66087c5e60 (svn r20935) -Codechange: only let the server side use a pool of connected sockets 14 years ago
rubidium 9858d699a3 (svn r20935) -Codechange: only let the server side use a pool of connected sockets 14 years ago
rubidium 6ff39fc5ec (svn r20929) -Codechange: make NetworkCloseClient a class method 14 years ago
rubidium 7ba07d9573 (svn r20929) -Codechange: make NetworkCloseClient a class method 14 years ago
rubidium 41e6567c0d (svn r20924) -Codechange: make the game connection packet handling look more like UDP/content packet handling 14 years ago
rubidium 0ca7e4e82e (svn r20924) -Codechange: make the game connection packet handling look more like UDP/content packet handling 14 years ago
rubidium 594faf45d9 (svn r20923) -Codechange: prepare creating sub-classes of NetworkClientSocket for server and client side 14 years ago
rubidium 8eb07d097e (svn r20923) -Codechange: prepare creating sub-classes of NetworkClientSocket for server and client side 14 years ago
rubidium 6d3c747d05 (svn r20553) -Feature: allow rate limiting of incoming commands 14 years ago