From aa6c7943aae6f0dad37b9223cd2dbde0f87571bd Mon Sep 17 00:00:00 2001 From: -gz <-gz@cardforge.org> Date: Tue, 6 Jan 2015 00:52:13 +0000 Subject: [PATCH] During drafting stop reporting basic lands as not found on stdout --- .../java/forge/limited/BoosterDraftAI.java | 23 +++++++++++++------ .../java/forge/limited/ReadDraftRankings.java | 5 ---- 2 files changed, 16 insertions(+), 12 deletions(-) diff --git a/forge-gui/src/main/java/forge/limited/BoosterDraftAI.java b/forge-gui/src/main/java/forge/limited/BoosterDraftAI.java index 3f7d4e068c7..2c1b3c8a429 100644 --- a/forge-gui/src/main/java/forge/limited/BoosterDraftAI.java +++ b/forge-gui/src/main/java/forge/limited/BoosterDraftAI.java @@ -18,6 +18,7 @@ package forge.limited; import forge.card.ColorSet; +import forge.card.MagicColor; import forge.deck.Deck; import forge.item.PaperCard; import forge.properties.ForgePreferences; @@ -54,6 +55,9 @@ public class BoosterDraftAI { // roughly equivalent to 25 ranks in a core set, or 15 ranks in a small set private static final double TAKE_BEST_THRESHOLD = 0.1; + // rank worse than any other card available to draft + private static final double RANK_UNPICKABLE = 999.0; + /** *
* Choose a CardPrinted from the list given.
@@ -121,8 +125,8 @@ public class BoosterDraftAI {
/**
* Sort cards by rank. Note that if pack has cards from different editions,
- * they could have the same rank. In that (hopefully rare) case, only one
- * will end up in the Map.
+ * they could have the same rank. Basic lands and unrecognised cards are
+ * rated worse than all other possible picks.
*
* @param chooseFrom
* List of cards
@@ -131,13 +135,18 @@ public class BoosterDraftAI {
private List