GUI, table: added drafts with single multiplayer and multiple 1vs1 games support (#13701)

- new tourney's single game mode allow to play tourneys/drafts with all players in one game without multiple rounds;
- it's allow to setup classic drafts with 1 vs 1 games and multiple rounds
- added AI opponents supported including draft bots from a public servers;
This commit is contained in:
Oleg Agafonov 2025-05-31 10:39:23 +04:00 committed by GitHub
parent a61851db09
commit f2826cc676
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
22 changed files with 247 additions and 256 deletions

View file

@ -121,8 +121,10 @@ public class MatchView implements Serializable {
for (TournamentPlayer tPlayer : table.getTournament().getPlayers()) {
sb2.append(tPlayer.getPlayer().getName()).append(": ").append(tPlayer.getResults()).append(' ');
}
} else if (table.getTournament().getOptions().getMatchOptions().isSingleGameTourney()) {
sb2.append("Started single game");
} else {
sb2.append("Canceled");
sb2.append("Canceled");
}
this.result = sb2.toString();
this.startTime = table.getTournament().getStartTime();

View file

@ -134,6 +134,8 @@ public class TableView implements Serializable {
// TOURNAMENT
if (table.getTournament().getOptions().getNumberRounds() > 0) {
this.gameType = this.gameType + ' ' + table.getTournament().getOptions().getNumberRounds() + " Rounds";
} else if (table.getTournament().getOptions().getMatchOptions().isSingleGameTourney()) {
this.gameType = this.gameType + " Single Game";
}
StringBuilder sb1 = new StringBuilder();
for (TournamentPlayer tp : table.getTournament().getPlayers()) {
@ -167,6 +169,10 @@ public class TableView implements Serializable {
infoTextShort.append(", Pick time: ").append(draftOptions.getTiming().getShortName());
infoTextLong.append("<br>Pick time: ").append(draftOptions.getTiming().getName());
}
if (table.getTournament().getOptions().getMatchOptions().isSingleGameTourney()) {
infoTextShort.append(", 1 GAME");
infoTextLong.append("<br>Single Game with all players (1 GAME)");
}
if (table.getTournament().getOptions().isWatchingAllowed()) {
infoTextShort.append(", SP");
infoTextLong.append("<br>Spectators allowed (SP)");

View file

@ -54,6 +54,8 @@ public class TournamentView implements Serializable {
if (tournament.getTournamentState().equals("Drafting") && tournament.getDraft() != null) {
runningInfo = "booster/card: " + tournament.getDraft().getBoosterNum() + '/' + (tournament.getDraft().getCardNum());
} else if (tournament.getOptions().getMatchOptions().isSingleGameTourney()) {
runningInfo = "running single game match";
} else {
runningInfo = "";
}