Update to 1.10.0-beta2

This commit is contained in:
dP
2020-01-06 18:49:34 +03:00
parent 599ccf0c2b
commit c7c3966eec
1366 changed files with 2926 additions and 5639 deletions

View File

@@ -1,5 +1,3 @@
/* $Id$ */
/*
* This file is part of OpenTTD.
* OpenTTD is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2.
@@ -1236,8 +1234,7 @@ void NetworkClientsToSpectators(CompanyID cid)
/* If our company is changing owner, go to spectators */
if (cid == _local_company) SetLocalCompany(COMPANY_SPECTATOR);
NetworkClientInfo *ci;
FOR_ALL_CLIENT_INFOS(ci) {
for (NetworkClientInfo *ci : NetworkClientInfo::Iterate()) {
if (ci->client_playas != cid) continue;
NetworkTextMessage(NETWORK_ACTION_COMPANY_SPECTATOR, CC_DEFAULT, false, ci->client_name);
ci->client_playas = COMPANY_SPECTATOR;
@@ -1301,8 +1298,7 @@ bool NetworkClientPreferTeamChat(const NetworkClientInfo *cio)
/* Only companies actually playing can speak to team. Eg spectators cannot */
if (!_settings_client.gui.prefer_teamchat || !Company::IsValidID(cio->client_playas)) return false;
const NetworkClientInfo *ci;
FOR_ALL_CLIENT_INFOS(ci) {
for (const NetworkClientInfo *ci : NetworkClientInfo::Iterate()) {
if (ci->client_playas == cio->client_playas && ci != cio) return true;
}