diff options
author | rubidium <rubidium@openttd.org> | 2008-12-23 11:55:46 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2008-12-23 11:55:46 +0000 |
commit | f8f7febe41311ff3562c57a10672e3a62174104b (patch) | |
tree | 0e0f56357371c5504e04f2c93c6baebc89f00607 /src/network/network.cpp | |
parent | 52fb6b7d7cec0734fb341939adce5199eeca7db6 (diff) | |
download | openttd-f8f7febe41311ff3562c57a10672e3a62174104b.tar.xz |
(svn r14725) -Change: make it clearer why (and that) MAX_CLIENTS isn't the amount of slots in the array, but one less as a dedicated server takes a slot too.
Diffstat (limited to 'src/network/network.cpp')
-rw-r--r-- | src/network/network.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/network/network.cpp b/src/network/network.cpp index 58826e1e3..eed479a1e 100644 --- a/src/network/network.cpp +++ b/src/network/network.cpp @@ -50,7 +50,7 @@ bool _network_available; ///< is network mode available? bool _network_dedicated; ///< are we a dedicated server? bool _is_network_server; ///< Does this client wants to be a network-server? NetworkServerGameInfo _network_game_info; -NetworkClientInfo _network_client_info[MAX_CLIENT_INFO]; +NetworkClientInfo _network_client_info[MAX_CLIENT_SLOTS]; NetworkCompanyState *_network_company_states = NULL; ClientID _network_own_client_id; ClientID _redirect_console_to_client; @@ -827,9 +827,9 @@ static void NetworkInitGameInfo() _network_game_info.clients_on = _network_dedicated ? 0 : 1; _network_game_info.start_date = ConvertYMDToDate(_settings_game.game_creation.starting_year, 0, 1); - // We use _network_client_info[MAX_CLIENT_INFO - 1] to store the server-data in it + // We use _network_client_info[MAX_CLIENT_SLOTS - 1] to store the server-data in it // The client identifier is CLIENT_ID_SERVER ( = 1) - ci = &_network_client_info[MAX_CLIENT_INFO - 1]; + ci = &_network_client_info[MAX_CLIENT_SLOTS - 1]; memset(ci, 0, sizeof(*ci)); ci->client_id = CLIENT_ID_SERVER; |