mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-15 18:28:00 +00:00
- Only reset quest new cards at the beginning of the match, not the end of each game
This commit is contained in:
@@ -12,6 +12,7 @@ import forge.game.event.GameEventAnteCardsSelected;
|
||||
import forge.game.player.LobbyPlayer;
|
||||
import forge.game.player.Player;
|
||||
import forge.properties.ForgePreferences.FPref;
|
||||
import forge.quest.QuestController;
|
||||
|
||||
/**
|
||||
* TODO: Write javadoc for this type.
|
||||
@@ -82,8 +83,14 @@ public class Match {
|
||||
|
||||
currentGame = new Game(players, gameType, this);
|
||||
|
||||
if ( getGameType() == GameType.Quest)
|
||||
currentGame.subscribeToEvents(Singletons.getModel().getQuest()); // this one listens to player's mulligans ATM
|
||||
if ( getGameType() == GameType.Quest) {
|
||||
QuestController qc = Singletons.getModel().getQuest();
|
||||
// Reset new list when the Match round starts, not when each game starts
|
||||
if (this.getPlayedGames().isEmpty()) {
|
||||
qc.getCards().resetNewList();
|
||||
}
|
||||
currentGame.subscribeToEvents(qc); // this one listens to player's mulligans ATM
|
||||
}
|
||||
|
||||
Singletons.getControl().attachToGame(currentGame);
|
||||
|
||||
|
||||
@@ -125,7 +125,6 @@ public class QuestWinLose extends ControlWinLose {
|
||||
@Override
|
||||
public final boolean populateCustomPanel() {
|
||||
this.getView().getBtnRestart().setVisible(false);
|
||||
qData.getCards().resetNewList();
|
||||
QuestController qc = Singletons.getModel().getQuest();
|
||||
|
||||
LobbyPlayer questPlayer = Singletons.getControl().getLobby().getQuestPlayer();
|
||||
@@ -159,7 +158,7 @@ public class QuestWinLose extends ControlWinLose {
|
||||
}
|
||||
|
||||
if (!match.isMatchOver()) {
|
||||
this.getView().getBtnQuit().setText("Quit (15 Credits)");
|
||||
this.getView().getBtnQuit().setText("Quit (-15 Credits)");
|
||||
return isAnte;
|
||||
} else {
|
||||
this.getView().getBtnContinue().setVisible(false);
|
||||
|
||||
Reference in New Issue
Block a user