diff options
author | rubidium <rubidium@openttd.org> | 2010-04-13 18:55:31 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2010-04-13 18:55:31 +0000 |
commit | 088282bcf8ce6d301fd8a5b0d8a3409bceaab32d (patch) | |
tree | e6a40c2bdaa2011f11cc3aaed25d4db3355ae9ad /src/network/network_server.cpp | |
parent | d2ed777fa5a9a1c39923ace958cd7e01f60de7f8 (diff) | |
download | openttd-088282bcf8ce6d301fd8a5b0d8a3409bceaab32d.tar.xz |
(svn r19620) -Fix: desync when a command is received and in the queue while a client starts joining, i.e. save the game state. This can happen in two ways: with frame_freq > 1 a command received in a previous frame might not be executed yet or when a command is received in the same frame as the join but before the savegame is made. In both cases the joining client would not get all commands to get in-sync with the server (and the other clients).
Diffstat (limited to 'src/network/network_server.cpp')
-rw-r--r-- | src/network/network_server.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/network/network_server.cpp b/src/network/network_server.cpp index a3cd53954..f4db459cb 100644 --- a/src/network/network_server.cpp +++ b/src/network/network_server.cpp @@ -353,6 +353,7 @@ DEF_SERVER_SEND_COMMAND(PACKET_SERVER_MAP) sent_packets = 4; // We start with trying 4 packets + NetworkSyncCommandQueue(cs); cs->status = STATUS_MAP; /* Mark the start of download */ cs->last_frame = _frame_counter; |