diff options
author | Darkvater <darkvater@openttd.org> | 2006-10-15 23:48:34 +0000 |
---|---|---|
committer | Darkvater <darkvater@openttd.org> | 2006-10-15 23:48:34 +0000 |
commit | d5baf25923869c6ec06ed31f387d8e59bf76066d (patch) | |
tree | b6419eb336f33a543168cce79ecd4086674ed9c6 /network_gui.c | |
parent | 7cac86186e8333fc98d2cd7eb863c6a7e5a58378 (diff) | |
download | openttd-d5baf25923869c6ec06ed31f387d8e59bf76066d.tar.xz |
(svn r6787) -Codechange: Use PLAYER_NEW_COMPANY as a player identifier wishing to become a
new player instead of a 0.
Diffstat (limited to 'network_gui.c')
-rw-r--r-- | network_gui.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/network_gui.c b/network_gui.c index c841eae42..cd6ab6d99 100644 --- a/network_gui.c +++ b/network_gui.c @@ -929,7 +929,7 @@ static void NetworkLobbyWindowWndProc(Window *w, WindowEvent *e) } break; case 8: /* New company */ - _network_playas = 0; + _network_playas = PLAYER_NEW_COMPANY; NetworkClientConnectGame(_network_last_host, _network_last_port); break; case 9: /* Spectate game */ @@ -1195,7 +1195,7 @@ static Window *PopupClientList(Window *w, int client_no, int x, int y) _clientlist_proc[i++] = &ClientList_SpeakToAll; if (_network_own_client_index != ci->client_index) { - if (_network_playas >= 1 && _network_playas <= MAX_PLAYERS) { + if (IsValidPlayer(_network_playas - 1)) { // We are no spectator if (ci->client_playas >= 1 && ci->client_playas <= MAX_PLAYERS) { GetString(_clientlist_action[i], STR_NETWORK_CLIENTLIST_GIVE_MONEY); |