forked from External/mage
* Added a simple skill level to set and filter for tables.
This commit is contained in:
parent
e3cb007848
commit
69b381779b
13 changed files with 462 additions and 177 deletions
|
|
@ -33,6 +33,7 @@ import java.util.ArrayList;
|
|||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.UUID;
|
||||
import mage.constants.SkillLevel;
|
||||
import mage.constants.TableState;
|
||||
import mage.game.Game;
|
||||
import mage.game.Seat;
|
||||
|
|
@ -56,6 +57,7 @@ public class TableView implements Serializable {
|
|||
private final String additionalInfo;
|
||||
private Date createTime;
|
||||
private TableState tableState;
|
||||
private final SkillLevel skillLevel;
|
||||
private final String tableStateText;
|
||||
private boolean isTournament;
|
||||
private List<SeatView> seats = new ArrayList<>();
|
||||
|
|
@ -127,6 +129,7 @@ public class TableView implements Serializable {
|
|||
addInfo.append(sbScore.toString());
|
||||
}
|
||||
this.additionalInfo = addInfo.toString();
|
||||
this.skillLevel = table.getMatch().getOptions().getSkillLevel();
|
||||
} else {
|
||||
// TOURNAMENT
|
||||
if (table.getTournament().getOptions().getNumberRounds() > 0) {
|
||||
|
|
@ -172,6 +175,7 @@ public class TableView implements Serializable {
|
|||
this.additionalInfo = infoText.toString();
|
||||
this.tableStateText = stateText.toString();
|
||||
this.deckType = table.getDeckType() + " " + table.getTournament().getBoosterInfo() + (tableNameInfo != null ? tableNameInfo : "");
|
||||
this.skillLevel = table.getTournament().getOptions().getMatchOptions().getSkillLevel();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -222,4 +226,8 @@ public class TableView implements Serializable {
|
|||
return tableStateText;
|
||||
}
|
||||
|
||||
public SkillLevel getSkillLevel() {
|
||||
return skillLevel;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue