mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2026-07-24 03:56:43 +00:00
Add: Company allow-list can be set to allow anyone.
This commit is contained in:
committed by
Peter Nelson
parent
a6803199d5
commit
da4dd91887
@@ -131,7 +131,7 @@ NetworkClientInfo::~NetworkClientInfo()
|
||||
bool NetworkClientInfo::CanJoinCompany(CompanyID company_id) const
|
||||
{
|
||||
Company *c = Company::GetIfValid(company_id);
|
||||
return c != nullptr && c->allow_list.Contains(this->public_key);
|
||||
return c != nullptr && (c->allow_any || c->allow_list.Contains(this->public_key));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user