diff --git a/forge-core/src/main/java/forge/card/CardDb.java b/forge-core/src/main/java/forge/card/CardDb.java index 5b6fe62e329..cdb48cfa730 100644 --- a/forge-core/src/main/java/forge/card/CardDb.java +++ b/forge-core/src/main/java/forge/card/CardDb.java @@ -171,13 +171,13 @@ public final class CardDb implements ICardDatabase, IDeckGenPool { List missingCards = new ArrayList<>(); CardEdition upcomingSet = null; Date today = new Date(); - boolean skip = false; + List skippedCardName = new ArrayList<>(); for (CardEdition e : editions.getOrderedEditions()) { boolean coreOrExpSet = e.getType() == CardEdition.Type.CORE || e.getType() == CardEdition.Type.EXPANSION; boolean isCoreExpSet = coreOrExpSet || e.getType() == CardEdition.Type.REPRINT; //todo sets with nonlegal cards should have tags in them so we don't need to specify the code here - skip = !loadNonLegalCards && (e.getType() == CardEdition.Type.FUNNY || e.getBorderColor() == CardEdition.BorderColor.SILVER); + boolean skip = !loadNonLegalCards && (e.getType() == CardEdition.Type.FUNNY || e.getBorderColor() == CardEdition.BorderColor.SILVER); if (logMissingPerEdition && isCoreExpSet) { System.out.print(e.getName() + " (" + e.getAllCardsInSet().size() + " cards)"); } @@ -188,8 +188,10 @@ public final class CardDb implements ICardDatabase, IDeckGenPool { for (CardEdition.CardInSet cis : e.getAllCardsInSet()) { CardRules cr = rulesByName.get(cis.name); - if (cr != null && !cr.getType().isBasicLand() && skip) + if (cr != null && !cr.getType().isBasicLand() && skip) { + skippedCardName.add(cis.name); continue; + } if (cr != null) { addSetCard(e, cis, cr); @@ -226,7 +228,7 @@ public final class CardDb implements ICardDatabase, IDeckGenPool { if (!contains(cr.getName())) { if (upcomingSet != null) { addCard(new PaperCard(cr, upcomingSet.getCode(), CardRarity.Unknown, 1)); - } else if(enableUnknownCards && !skip) { + } else if(enableUnknownCards && !skippedCardName.contains(cr.getName())) { System.err.println("The card " + cr.getName() + " was not assigned to any set. Adding it to UNKNOWN set... to fix see res/editions/ folder. "); addCard(new PaperCard(cr, CardEdition.UNKNOWN.getCode(), CardRarity.Special, 1)); }