diff --git a/Mage.Client/src/main/java/mage/client/util/sets/ConstructedFormats.java b/Mage.Client/src/main/java/mage/client/util/sets/ConstructedFormats.java index 4404573e645..ce100ce7c3d 100644 --- a/Mage.Client/src/main/java/mage/client/util/sets/ConstructedFormats.java +++ b/Mage.Client/src/main/java/mage/client/util/sets/ConstructedFormats.java @@ -17,12 +17,13 @@ import mage.cards.repository.CardRepository; public class ConstructedFormats { private static final String[] constructedFormats = {"- All Sets", "- Standard", "- Extended", "- Modern", - "* Return to Ravnica Block", "Gatecrash","Return to Ravnica", "Magic 2013", - "* Innistrad Block", "Avacyn Restored", "Dark Ascension", "Innistrad", "Magic 2012", - "Planechase 2012", + "* Return to Ravnica Block", "Dragon's Maze", "Gatecrash","Return to Ravnica", + "Magic 2013", "Planechase 2012", + "* Innistrad Block", "Avacyn Restored", "Dark Ascension", "Innistrad", + "Magic 2012", "Commander", "* Scars of Mirrodin Block", "New Phyrexia", "Mirrodin Besieged", "Scars of Mirrodin", "Magic 2011", - "* Zendikar Block", "Rise of the Eldrazi", "Worldwake", "Zendikar", "Magic 2010", - "Planechase", + "* Zendikar Block", "Rise of the Eldrazi", "Worldwake", "Zendikar", + "Magic 2010", "Planechase", "* Shards of Alara Block", "Alara Reborn", "Conflux", "Shards of Alara", "* Shadowmoor Block", "Shadowmoor", "Eventide", "* Lorwyn Block", "Lorwyn", "Morningtide", @@ -286,7 +287,7 @@ public class ConstructedFormats { return Arrays.asList("AVR"); } if (format.equals("* Return to Ravnica Block")) { - return Arrays.asList("RTR", "GTC"); + return Arrays.asList("RTR", "GTC", "DGM"); } if (format.equals("Return to Ravnica")) { return Arrays.asList("RTR"); @@ -294,6 +295,9 @@ public class ConstructedFormats { if (format.equals("Gatecrash")) { return Arrays.asList("GTC"); } + if (format.equals("Dragon's Maze")) { + return Arrays.asList("DGM"); + } if (format.equals("Limited Edition Alpha")) { return Arrays.asList("LEA"); } @@ -344,6 +348,9 @@ public class ConstructedFormats { if (format.equals("Planechase")) { return Arrays.asList("HOP"); } + if (format.equals("Commander")) { + return Arrays.asList("CMD"); + } if (format.equals("Planechase 2012")) { return Arrays.asList("PC2"); } 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 7f77866fd77..d6cae7650f0 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 @@ -36,9 +36,10 @@ public class GathererSets implements Iterable { "DDF", "ALA", "CON", "ARB", "ZEN", "WWK", "ROE", - "SOM", "MBS", "NPH", + "SOM", "MBS", "NPH", + "CMD", "ISD", "DKA", "AVR", - "RTR", "GTC"}; + "RTR", "GTC", "DGM"}; private static final HashMap symbolsReplacements = new HashMap(); static { diff --git a/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/MagicCardsImageSource.java b/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/MagicCardsImageSource.java index 6319ff16e98..00de2ec4477 100644 --- a/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/MagicCardsImageSource.java +++ b/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/MagicCardsImageSource.java @@ -15,6 +15,7 @@ public class MagicCardsImageSource implements CardImageSource { private static final Map setNameReplacement = new HashMap() { { + put("DGM", "dragons-maze"); put("GTC", "gatecrash"); put("RTR", "return-to-ravnica"); put("M13", "magic-2013"); @@ -33,6 +34,7 @@ public class MagicCardsImageSource implements CardImageSource { put("WWK", "worldwake"); put("ZEN", "zendikar"); put("HOP", "planechase"); + put("CMD", "commander"); put("PC2", "planechase-2012-edition"); put("M10", "magic-2010"); put("GVL", "duel-decks-garruk-vs-liliana"); diff --git a/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/WizardCardsImageSource.java b/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/WizardCardsImageSource.java index 21a85c25f35..13c39869e68 100644 --- a/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/WizardCardsImageSource.java +++ b/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/WizardCardsImageSource.java @@ -28,6 +28,7 @@ public class WizardCardsImageSource implements CardImageSource { public WizardCardsImageSource() { sets = new HashMap(); setsAliases = new HashMap(); + setsAliases.put("DGM", "dragonsmaze/cig"); setsAliases.put("GTC", "gatecrash/cig"); setsAliases.put("RTR", "returntoravnica/cig"); setsAliases.put("M13", "magic2013/cig"); diff --git a/Mage.Client/src/main/resources/image.url.properties b/Mage.Client/src/main/resources/image.url.properties index beb0bce94b8..f7b76ebd66a 100644 --- a/Mage.Client/src/main/resources/image.url.properties +++ b/Mage.Client/src/main/resources/image.url.properties @@ -59,6 +59,7 @@ drk=dk ptk=p3k gur=guru mpr=mprp -ignore.urls=TOK,EMBLEM +# Remove DGM as sson as the images can be downloaded +ignore.urls=TOK,EMBLEM,DGM # sets ordered by release time (newest goes first) token.lookup.order=GTC,RTR,M13,AVR,DDI,DKA,ISD,M12,NPH,MBS,SOM,M11,ROE,PVC,WWK,ZEN,M10,GVL,ARB,DVD,CFX,JVC,ALA,EVE,SHM,EVG,MOR,LRW,10E,CLS,CHK \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/Commander.java b/Mage.Sets/src/mage/sets/Commander.java new file mode 100644 index 00000000000..f6437949259 --- /dev/null +++ b/Mage.Sets/src/mage/sets/Commander.java @@ -0,0 +1,53 @@ +/* +* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. +* +* Redistribution and use in source and binary forms, with or without modification, are +* permitted provided that the following conditions are met: +* +* 1. Redistributions of source code must retain the above copyright notice, this list of +* conditions and the following disclaimer. +* +* 2. Redistributions in binary form must reproduce the above copyright notice, this list +* of conditions and the following disclaimer in the documentation and/or other materials +* provided with the distribution. +* +* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED +* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR +* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +* +* The views and conclusions contained in the software and documentation are those of the +* authors and should not be interpreted as representing official policies, either expressed +* or implied, of BetaSteward_at_googlemail.com. +*/ + +package mage.sets; + +import java.util.GregorianCalendar; +import mage.Constants.SetType; +import mage.cards.ExpansionSet; + +/** + * + * @author LevelX2 + */ + + +public class Commander extends ExpansionSet { + + private static final Commander fINSTANCE = new Commander(); + + public static Commander getInstance() { + return fINSTANCE; + } + + private Commander() { + super("Magic: The Gathering-Commander", "CMD", "", "mage.sets.commander", new GregorianCalendar(2011, 6, 17).getTime(), SetType.REPRINT); + } + +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/DragonsMaze.java b/Mage.Sets/src/mage/sets/DragonsMaze.java new file mode 100644 index 00000000000..ee10ab7d85d --- /dev/null +++ b/Mage.Sets/src/mage/sets/DragonsMaze.java @@ -0,0 +1,61 @@ +/* + * Copyright 2011 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ + +package mage.sets; + +import java.util.GregorianCalendar; +import mage.Constants; +import mage.cards.ExpansionSet; + +/** + * + * @author LevelX2 + */ + + +public class DragonsMaze extends ExpansionSet { + + private static final DragonsMaze fINSTANCE = new DragonsMaze(); + + public static DragonsMaze getInstance() { + return fINSTANCE; + } + + private DragonsMaze() { + super("Dragon's Maze", "DGM", "seticon_mtggtc", "mage.sets.dragonsmaze", new GregorianCalendar(2013, 5, 03).getTime(), Constants.SetType.EXPANSION); + this.blockName = "Return to Ravnica"; + this.hasBoosters = true; + this.numBoosterLands = 1; + this.numBoosterCommon = 10; + this.numBoosterUncommon = 3; + this.numBoosterRare = 1; + this.ratioBoosterMythic = 8; + this.parentSet = ReturnToRavnica.getInstance(); + this.hasBasicLands = false; + } +} diff --git a/Mage.Sets/src/mage/sets/Gatecrash.java b/Mage.Sets/src/mage/sets/Gatecrash.java index 2f0606e21f3..2e518c7b695 100644 --- a/Mage.Sets/src/mage/sets/Gatecrash.java +++ b/Mage.Sets/src/mage/sets/Gatecrash.java @@ -45,7 +45,7 @@ public class Gatecrash extends ExpansionSet { private Gatecrash() { super("Gatecrash", "GTC", "seticon_mtggtc", "mage.sets.gatecrash", new GregorianCalendar(2013, 2, 01).getTime(), SetType.EXPANSION); - this.blockName = "Gatecrash"; + this.blockName = "Return to Ravnica"; this.hasBoosters = true; this.numBoosterLands = 1; this.numBoosterCommon = 10; diff --git a/Utils/known-sets.txt b/Utils/known-sets.txt index 24150f12b73..1a90c4fe811 100644 --- a/Utils/known-sets.txt +++ b/Utils/known-sets.txt @@ -77,4 +77,4 @@ Innistrad|innistrad| Dark Ascension|darkascension| Avacyn Restored|avacynrestored| Gatecrash|gatecrash| -Commander|commander| \ No newline at end of file +Magic: The Gathering-Commander|commander| \ No newline at end of file diff --git a/Utils/mtg-sets-data.txt b/Utils/mtg-sets-data.txt index c0fc44c4601..9498dacff59 100644 --- a/Utils/mtg-sets-data.txt +++ b/Utils/mtg-sets-data.txt @@ -26,6 +26,7 @@ Dark Ascension|DKA| Darksteel|DST| Dissension|DIS| Deckmasters|DKM| +Dragon's Maze|DGM| The Dark|DRK| Duel Decks: Divine vs. Demonic|DVD| Duel Decks: Elspeth vs. Tezzeret|DDF|