mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-08-21 13:39:09 +00:00
(svn r16559) -Codechange: introduce Company::IsValidAiID() and Company::IsValidHumanID(), don't use IsHumanCompany() where possible
This commit is contained in:
@@ -686,7 +686,7 @@ DEF_SERVER_RECEIVE_COMMAND(PACKET_CLIENT_JOIN)
|
||||
}
|
||||
break;
|
||||
default: // Join another company (companies 1-8 (index 0-7))
|
||||
if (!Company::IsValidID(playas) || !IsHumanCompany(playas)) {
|
||||
if (!Company::IsValidHumanID(playas)) {
|
||||
SEND_COMMAND(PACKET_SERVER_ERROR)(cs, NETWORK_ERROR_COMPANY_MISMATCH);
|
||||
return;
|
||||
}
|
||||
|
Reference in New Issue
Block a user