forked from External/mage
This commit is contained in:
parent
2f18bb3787
commit
4d5884c5ba
7 changed files with 67 additions and 1 deletions
|
|
@ -68,7 +68,8 @@ public class GathererSets implements Iterable<DownloadJob> {
|
|||
// "PALP" -- Gatherer does not have the set Asia Pacific Land Program
|
||||
// "ATH" -- has cards from many sets, symbol does not exist on gatherer
|
||||
// "CP", "DPA", "PELP", "PGPX", "PGRU", "H17", "JR", "SWS", // need to fix
|
||||
"H09", "PD2", "PD3", "UNH", "CM1", "V11", "A25", "UST", "IMA", "DD2", "EVG", "DDC", "DDE", "DDD", "CHR", "G18", "GVL", "S00", "S99", "UGL" // ok
|
||||
"H09", "PD2", "PD3", "UNH", "CM1", "V11", "A25", "UST", "IMA", "DD2", "EVG", "DDC", "DDE", "DDD", "CHR", "G18", "GVL", "S00", "S99", "UGL", // ok
|
||||
"FOUL"
|
||||
// current testing
|
||||
};
|
||||
|
||||
|
|
@ -168,6 +169,8 @@ public class GathererSets implements Iterable<DownloadJob> {
|
|||
codeReplacements.put("USG", "UZ");
|
||||
codeReplacements.put("VIS", "VI");
|
||||
codeReplacements.put("WTH", "WL");
|
||||
// ??? maybe
|
||||
codeReplacements.put("FOUL", "FDN");
|
||||
}
|
||||
|
||||
public GathererSets() {
|
||||
|
|
|
|||
|
|
@ -2,6 +2,8 @@ package org.mage.plugins.card.dl.sources;
|
|||
|
||||
import org.tritonus.share.ArraySet;
|
||||
|
||||
import mage.sets.FoulMagics;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Locale;
|
||||
import java.util.Map;
|
||||
|
|
@ -566,6 +568,7 @@ public class ScryfallImageSupportCards {
|
|||
add("FDN"); // Foundations
|
||||
add("J25"); // Foundations Jumpstart
|
||||
add("DFT"); // Aetherdrift
|
||||
add("FOUL"); // FOUL FUCKING MAGICS
|
||||
|
||||
// Custom sets using Scryfall images - must provide a direct link for each card in directDownloadLinks
|
||||
add("CALC"); // Custom Alchemized versions of existing cards
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
package org.mage.plugins.card.images;
|
||||
|
||||
import mage.sets.FoulMagics;
|
||||
import mage.util.CardUtil;
|
||||
|
||||
import java.util.Objects;
|
||||
|
|
@ -26,6 +27,7 @@ public class CardDownloadData {
|
|||
this.collectorId = collectorId;
|
||||
this.isUsesVariousArt = isUsesVariousArt;
|
||||
this.imageNumber = imageNumber;
|
||||
this.seekSet();
|
||||
}
|
||||
|
||||
public CardDownloadData(final CardDownloadData card) {
|
||||
|
|
@ -39,6 +41,18 @@ public class CardDownloadData {
|
|||
this.isFlippedSide = card.isFlippedSide;
|
||||
this.isSplitCard = card.isSplitCard;
|
||||
this.isUsesVariousArt = card.isUsesVariousArt;
|
||||
this.seekSet();
|
||||
}
|
||||
|
||||
public void seekSet() {
|
||||
// I love hardcoding exceptions
|
||||
if (this.set.equals("FOUL")) {
|
||||
System.out.println(this.name);
|
||||
System.out.println(this.collectorId);
|
||||
|
||||
this.set = FoulMagics.getInstance().setMap.get(this.name).get(this.collectorId);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
|
|
@ -1310,6 +1310,7 @@ public class CardView extends SimpleCardView {
|
|||
if (expansionSetCode == null) {
|
||||
expansionSetCode = "";
|
||||
}
|
||||
|
||||
return expansionSetCode;
|
||||
}
|
||||
|
||||
|
|
|
|||
43
Mage.Sets/src/mage/sets/FoulMagics.java
Normal file
43
Mage.Sets/src/mage/sets/FoulMagics.java
Normal file
|
|
@ -0,0 +1,43 @@
|
|||
package mage.sets;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
|
||||
import mage.cards.ExpansionSet;
|
||||
import mage.constants.SetType;
|
||||
|
||||
/**
|
||||
* @author Failure
|
||||
*/
|
||||
public final class FoulMagics extends ExpansionSet {
|
||||
|
||||
public HashMap<String, HashMap<String, String>> setMap = new HashMap<String, HashMap<String, String>>();
|
||||
private static final FoulMagics instance = new FoulMagics();
|
||||
|
||||
public static FoulMagics getInstance() {
|
||||
return instance;
|
||||
}
|
||||
|
||||
private FoulMagics() {
|
||||
super("Foul Magics", "FOUL", ExpansionSet.buildDate(2024, 11, 29), SetType.EXPANSION);
|
||||
this.blockName = "Foul Magics"; // for sorting in GUI
|
||||
this.hasBasicLands = true;
|
||||
this.hasBoosters = false; // temporary
|
||||
|
||||
List<ExpansionSet> sets = new ArrayList<ExpansionSet>();
|
||||
sets.add(Foundations.getInstance());
|
||||
sets.add(GuildsOfRavnica.getInstance());
|
||||
sets.add(ReturnToRavnica.getInstance());
|
||||
|
||||
|
||||
for (ExpansionSet set : sets) {
|
||||
for (SetCardInfo card : set.getSetCardInfo()) {
|
||||
cards.add(card);
|
||||
setMap.putIfAbsent(card.getName(), new HashMap<String, String>());
|
||||
setMap.get(card.getName()).put(card.getCardNumber(), set.getCode());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -97,6 +97,7 @@ Fallen Empires|FallenEmpires|
|
|||
Fate Reforged|FateReforged|
|
||||
Fifth Dawn|FifthDawn|
|
||||
Fifth Edition|FifthEdition|
|
||||
Foul Magics|FoulMagics|
|
||||
Foundations|Foundations|
|
||||
Foundations Jumpstart|FoundationsJumpstart|
|
||||
Fourth Edition|FourthEdition|
|
||||
|
|
|
|||
|
|
@ -113,6 +113,7 @@ Fallen Empires|FEM|
|
|||
Friday Night Magic|FNMP|
|
||||
Fate Reforged|FRF|
|
||||
Foundations|FDN|
|
||||
Foul Magics|FOUL|
|
||||
Foundations Jumpstar|J25|
|
||||
Future Sight|FUT|
|
||||
Global Series: Jiang Yanggu & Mu Yanling|GS1|
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue