diff --git a/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/GathererSets.java b/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/GathererSets.java index 5330c542cf..1d01f9f770 100644 --- a/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/GathererSets.java +++ b/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/GathererSets.java @@ -238,25 +238,24 @@ public class GathererSets implements Iterable { } //*/ - // 3. wrong sets config with alternative numbers - // TODO: some sets have cards above maxCardNumberInBooster, need to check it (search code for maxCardNumberInBooster), maybe delete at all after getCardNumberAsInt implement - if ((set.getMaxCardNumberInBooster() == 0) || (set.getMaxCardNumberInBooster() == Integer.MAX_VALUE)) - { - for(ExpansionSet.SetCardInfo card: set.getSetCardInfo()){ - if (String.valueOf(card.getCardNumberAsInt()).length() != card.getCardNumber().length()){ - logger.error(String.format("Symbols: set have alternative card but do not config to it: %s (%s)", set.getCode(), set.getName())); - break; - } + // 3. info: sets with alternative numbers + for(ExpansionSet.SetCardInfo card: set.getSetCardInfo()){ + if (String.valueOf(card.getCardNumberAsInt()).length() != card.getCardNumber().length()){ + logger.info(String.format("Symbols: set have alternative card but do not config to it: %s (%s)", set.getCode(), set.getName())); + break; } } - // 4. have nonland card above maxboosternumber (info) + // 4. info: sets with missing cards for boosters (todo: what about +20 number for alternative land arts?) if (set.getMaxCardNumberInBooster() != Integer.MAX_VALUE) { for(ExpansionSet.SetCardInfo card: set.getSetCardInfo()){ - if (card.getRarity() == Rarity.LAND) { continue; } if (card.getCardNumberAsInt() > set.getMaxCardNumberInBooster()){ - logger.error(String.format("Symbols: set setup to cut off cards for boosters, non land card will be missing: %s (%s), %s - %s", set.getCode(), set.getName(), card.getCardNumber(), card.getName())); + if (card.getRarity() == Rarity.LAND) { + logger.info(String.format("Symbols: set's booster have land above max card number: %s (%s), %s - %s", set.getCode(), set.getName(), card.getCardNumber(), card.getName())); + }else { + logger.info(String.format("Symbols: set's booster missing nonland card:: %s (%s), %s - %s", set.getCode(), set.getName(), card.getCardNumber(), card.getName())); + } } } } diff --git a/Mage/src/main/java/mage/cards/ExpansionSet.java b/Mage/src/main/java/mage/cards/ExpansionSet.java index 790657e19b..c14340386e 100644 --- a/Mage/src/main/java/mage/cards/ExpansionSet.java +++ b/Mage/src/main/java/mage/cards/ExpansionSet.java @@ -393,8 +393,7 @@ public abstract class ExpansionSet implements Serializable { criteria.doubleFaced(false); } savedCardsInfos = CardRepository.instance.findCards(criteria); - // Workaround after card number is numeric (p.s. card number is not numeric for some cards) - // TODO: some sets have фывфывфывфывфыв + // Workaround after card number is numeric if (maxCardNumberInBooster != Integer.MAX_VALUE) { savedCardsInfos.removeIf(next -> next.getCardNumberAsInt() > maxCardNumberInBooster && rarity != Rarity.LAND); }