mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-19 04:08:01 +00:00
Removed ability to concede for AI in tournaments.
Rewrote booster configuration selection for tournaments. Minor balance adjustments for tournaments.
This commit is contained in:
@@ -21,6 +21,7 @@ public class QuestDraftUtils {
|
||||
private static List<DraftMatchup> matchups = new ArrayList<DraftMatchup>();
|
||||
|
||||
public static boolean matchInProgress = false;
|
||||
public static boolean aiMatchInProgress = false;
|
||||
private static boolean waitForUserInput = false;
|
||||
|
||||
public static void continueMatch(Game lastGame) {
|
||||
@@ -148,6 +149,9 @@ public class QuestDraftUtils {
|
||||
public static void update() {
|
||||
|
||||
if (matchups.isEmpty()) {
|
||||
if (!matchInProgress) {
|
||||
aiMatchInProgress = false;
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -176,8 +180,10 @@ public class QuestDraftUtils {
|
||||
if (!nextMatch.hasHumanPlayer) {
|
||||
GuiBase.getInterface().disableOverlay();
|
||||
waitForUserInput = false;
|
||||
aiMatchInProgress = true;
|
||||
} else {
|
||||
waitForUserInput = true;
|
||||
aiMatchInProgress = false;
|
||||
}
|
||||
|
||||
GuiBase.getInterface().startMatch(GameType.QuestDraft, nextMatch.matchStarter);
|
||||
|
||||
@@ -44,6 +44,7 @@ import forge.item.InventoryItem;
|
||||
import forge.menus.IMenuProvider;
|
||||
import forge.model.FModel;
|
||||
import forge.properties.ForgePreferences.FPref;
|
||||
import forge.screens.home.quest.QuestDraftUtils;
|
||||
import forge.screens.match.controllers.*;
|
||||
import forge.screens.match.menus.CMatchUIMenus;
|
||||
import forge.screens.match.views.*;
|
||||
@@ -475,7 +476,7 @@ public enum CMatchUI implements ICDoc, IMenuProvider {
|
||||
|
||||
/** Concede game, bring up WinLose UI. */
|
||||
public void concede() {
|
||||
if (FOverlay.SINGLETON_INSTANCE.getPanel().isShowing()) {
|
||||
if (FOverlay.SINGLETON_INSTANCE.getPanel().isShowing() || QuestDraftUtils.aiMatchInProgress) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user