summaryrefslogtreecommitdiff
path: root/src/network/network.h
AgeCommit message (Collapse)Author
2019-03-20Remove: ENABLE_NETWORK switchPatric Stout
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.
2014-04-08(svn r26449) -Add: Allow more sound sleep for dedicated servers when there's ↵planetmaker
nothing to do and nobody paying attention
2011-01-19(svn r21853) -Codechange: HashCurrentCompanyPassword is only used by ↵rubidium
servers, so move it to network_server.* (dihedral)
2011-01-19(svn r21852) -Codechange: generalise GenerateCompanyPasswordHash (dihedral)rubidium
2011-01-19(svn r21850) -Codechange: move password hashing to a more general location ↵rubidium
(dihedral)
2010-01-15(svn r18809) -Codechange/Cleanup: remove unneeded headers from some files, ↵rubidium
if a header require a header make it include that header
2009-08-21(svn r17248) -Fix: add GPL license notice where appropriaterubidium
2009-05-19(svn r16360) -Codechange: don't use _network_playas as a 'second' ↵rubidium
_local_company, but only as a storage location for the company you want to join in MP.
2008-09-30(svn r14422) -Codechange: also reflect the changes of r14421 in the filenames.rubidium
2008-09-30(svn r14421) -Codechange: rename all player variables/types to company *or* ↵rubidium
client so it is immediatelly clear which one you are working with.
2008-08-11(svn r14047) -Codechange: move chatmessage handling to the network directory ↵rubidium
as that's the only case chat messages are used. Furthermore remove any trace of chatmessages when compiling without network support.
2008-06-09(svn r13433) -Codechange: remove a now useless global variable.rubidium
-Fix: MP advertising was not advertising.
2008-05-30(svn r13343) -Codechange: reorder/move variable/functions in the network ↵rubidium
headers so that nothing from the network directory needs to include basically all network headers.
2008-05-29(svn r13334) -Codechange: move the network settings variables from ↵rubidium
network/network_internal to settings.
2008-05-06(svn r12971) -Documentation: add @file in files that missed them and add ↵rubidium
something more than whitespace as description of files that don't have a description.
2008-05-04(svn r12944) -Codechange: use rev.h instead of externs at many placessmatz
2008-01-13(svn r11840) -Codechange: split network.h so not everything in there needs ↵rubidium
to be included when wanting to know whether we are a server.
2008-01-13(svn r11829) -Feature: allow reloading openttd.cfg when starting a new game ↵rubidium
on a dedicated server. Patch by dihedral.
2008-01-12(svn r11818) -Codechange: split player.h into smaller pieces.rubidium
2008-01-11(svn r11811) -Fix: make compilation without networking work again (and thus ↵rubidium
move the debugdumpcommand stuff out of the network 'area').
2007-12-22(svn r11682) -Codechange: move some 'generic' geometry related types into a ↵rubidium
single file and do not include gfx.h everywhere to get a Point type.
2007-12-02(svn r11556) -Feature: allow setting a default password for new companies in ↵rubidium
network games.
2007-10-30(svn r11357) -Fix: NetworkUniqueID could be 80 chars, while the max size we ↵truelight
generate is 32. So reduce the size a bit. Pointed out by dihedral, so give him a big hug ;)
2007-09-12(svn r11089) -Codechange: add revision detection to MSVC.rubidium
2007-07-07(svn r10462) -Add: a command dumper/loader that could be enabled ↵rubidium
compile-time and server side only to aid debugging some desyncs, i.e. dump the stream of commands so it could be replayed in exactly the same way later. This should primarily be used to make desyncs more easily reproducable, so it can be properly debugged.
2007-06-21(svn r10246) -Fix (r10297): some forgotten money conversions and truncation ↵rubidium
issues. Thanks to benc for providing the patch.
2007-06-04(svn r10035) -Change: simplified network language string sortingglx
2007-06-04(svn r10032) -Add: sort the strings in server language dropdownglx
2007-03-07(svn r9051) -Codechange: typedef [enum|struct] Y {} X; -> [enum|struct] X {};rubidium
2007-03-07(svn r9050) -Codechange: Foo(void) -> Foo()rubidium
2007-03-01(svn r8949) -Codechange: only test the first NETWORK_REVISION_LENGTH - 1 ↵rubidium
characters when determining network compatability. This makes it possible to have 'long' branch names while still being able to play network games.
2007-02-08(svn r8631) -Add: added parameter -l ip[:port] to ./openttd, which redirects ↵truelight
DEBUG() to a remote connection over TCP For example, launch on 192.168.0.1 with, say, netcat a listener: netcat -l -p 3982 Launch OpenTTD on a remote host (say, PSP): ./openttd -l 192.168.0.1 -d9 And you get all debug information on 192.168.0.1. Very useful for debugging Portable systems.
2007-02-02(svn r8546) -Codechange: add a seperate (wrapper) functions to send/receive ↵rubidium
booleans.
2007-02-02(svn r8544) -Codechange: move game list related function/struct declarations ↵rubidium
to network_gamelist.h
2007-02-02(svn r8543) -Codechange: make a real difference between querying the server ↵rubidium
via UDP and TCP.
2007-02-01(svn r8520) -Fix/Feature: requery gameservers that did not respond to their ↵rubidium
first query.
2007-01-17(svn r8198) -Codechange: two global variables are not needed when network is ↵rubidium
disabled.
2007-01-12(svn r8078) -Codechange: rewrite UDP part of the network code to make use ↵rubidium
classes. This is only one of the many steps to really cleanup the network code.
2007-01-10(svn r8038) -Merge: the cpp branch. Effort of KUDr, Celestar, glx, Smoovius, ↵rubidium
stillunknown and pv2b.
2007-01-04(svn r7825) -Codechange: make NetworkUDPClose close a single UDP socket. Use ↵rubidium
NetworkUDPStop to close all opened udp sockets (those were called NetworkUDPClose).
2007-01-02(svn r7759) -Merge: makefile rewrite. This merge features:rubidium
- A proper ./configure, so everything needs to be configured only once, not for every make. - Usage of makedepend when available. This greatly reduces the time needed for generating the dependencies. - A generator for all project files. There is a single file with sources, which is used to generate Makefiles and the project files for MSVC. - Proper support for OSX universal binaries. - Object files for non-MSVC compiles are also placed in separate directories, making is faster to switch between debug and release compiles and it does not touch the directory with the source files. - Functionality to make a bundle of all needed files for for example a nightly or distribution of a binary with all needed GRFs and language files. Note: as this merge moves almost all files, it is recommended to make a backup of your working copy before updating your working copy.