mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-04-27 07:48:01 -07:00
merged with master
This commit is contained in:
commit
5cfb034452
416 changed files with 65983 additions and 19400 deletions
|
|
@ -157,12 +157,11 @@ void GameSelector::checkResponse(const Response &response)
|
|||
|
||||
void GameSelector::actJoin()
|
||||
{
|
||||
bool spectator = sender() == spectateButton;
|
||||
|
||||
QModelIndex ind = gameListView->currentIndex();
|
||||
if (!ind.isValid())
|
||||
return;
|
||||
const ServerInfo_Game &game = gameListModel->getGame(ind.data(Qt::UserRole).toInt());
|
||||
bool spectator = sender() == spectateButton || game.player_count() == game.max_players();
|
||||
bool overrideRestrictions = !tabSupervisor->getAdminLocked();
|
||||
QString password;
|
||||
if (game.with_password() && !(spectator && !game.spectators_need_password()) && !overrideRestrictions) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue