mirror of
https://github.com/correl/mage.git
synced 2024-12-25 03:00:15 +00:00
[STX] Implemented Dragon's Approach
This commit is contained in:
parent
61c7723e3b
commit
c83db2cad3
3 changed files with 66 additions and 1 deletions
63
Mage.Sets/src/mage/cards/d/DragonsApproach.java
Normal file
63
Mage.Sets/src/mage/cards/d/DragonsApproach.java
Normal file
|
@ -0,0 +1,63 @@
|
|||
package mage.cards.d;
|
||||
|
||||
import mage.abilities.costs.CompositeCost;
|
||||
import mage.abilities.costs.common.ExileFromGraveCost;
|
||||
import mage.abilities.costs.common.ExileSourceCost;
|
||||
import mage.abilities.effects.common.DamagePlayersEffect;
|
||||
import mage.abilities.effects.common.DoIfCostPaid;
|
||||
import mage.abilities.effects.common.InfoEffect;
|
||||
import mage.abilities.effects.common.search.SearchLibraryPutInPlayEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SubType;
|
||||
import mage.constants.TargetController;
|
||||
import mage.filter.FilterCard;
|
||||
import mage.filter.common.FilterCreatureCard;
|
||||
import mage.filter.predicate.mageobject.NamePredicate;
|
||||
import mage.target.common.TargetCardInLibrary;
|
||||
import mage.target.common.TargetCardInYourGraveyard;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
public final class DragonsApproach extends CardImpl {
|
||||
|
||||
private static final FilterCard filter = new FilterCreatureCard("a Dragon creature card");
|
||||
private static final FilterCard filter2 = new FilterCard("cards named Dragon's Approach");
|
||||
|
||||
static {
|
||||
filter.add(SubType.DRAGON.getPredicate());
|
||||
filter2.add(new NamePredicate("Dragon's Approach"));
|
||||
}
|
||||
|
||||
public DragonsApproach(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{2}{R}");
|
||||
|
||||
// Dragon's Approach deals 3 damage to each opponent. You may exile Dragon's Approach and four cards named Dragon's Approach from your graveyard. If you do, search your library for a Dragon creature card, put it onto the battlefield, then shuffle.
|
||||
this.getSpellAbility().addEffect(new DamagePlayersEffect(3, TargetController.OPPONENT));
|
||||
this.getSpellAbility().addEffect(new DoIfCostPaid(
|
||||
new SearchLibraryPutInPlayEffect(new TargetCardInLibrary()),
|
||||
new CompositeCost(
|
||||
new ExileSourceCost(), new ExileFromGraveCost(new TargetCardInYourGraveyard(filter2)),
|
||||
"exile {this} and four cards named Dragon's Approach from your graveyard"
|
||||
)
|
||||
));
|
||||
|
||||
// A deck can have any number of cards named Dragon's Approach.
|
||||
this.getSpellAbility().addEffect(new InfoEffect(
|
||||
"A deck can have any number of cards named Dragon's Approach."
|
||||
).concatBy("<br>"));
|
||||
}
|
||||
|
||||
private DragonsApproach(final DragonsApproach card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public DragonsApproach copy() {
|
||||
return new DragonsApproach(this);
|
||||
}
|
||||
}
|
|
@ -81,6 +81,7 @@ public final class StrixhavenSchoolOfMages extends ExpansionSet {
|
|||
cards.add(new SetCardInfo("Dina, Soul Steeper", 178, Rarity.UNCOMMON, mage.cards.d.DinaSoulSteeper.class));
|
||||
cards.add(new SetCardInfo("Divide by Zero", 41, Rarity.UNCOMMON, mage.cards.d.DivideByZero.class));
|
||||
cards.add(new SetCardInfo("Double Major", 179, Rarity.RARE, mage.cards.d.DoubleMajor.class));
|
||||
cards.add(new SetCardInfo("Dragon's Approach", 97, Rarity.COMMON, mage.cards.d.DragonsApproach.class));
|
||||
cards.add(new SetCardInfo("Dragonsguard Elite", 127, Rarity.RARE, mage.cards.d.DragonsguardElite.class));
|
||||
cards.add(new SetCardInfo("Dramatic Finale", 180, Rarity.RARE, mage.cards.d.DramaticFinale.class));
|
||||
cards.add(new SetCardInfo("Dream Strix", 42, Rarity.RARE, mage.cards.d.DreamStrix.class));
|
||||
|
|
|
@ -17,7 +17,8 @@ public class Constructed extends DeckValidator {
|
|||
private static final Logger logger = Logger.getLogger(DeckValidator.class);
|
||||
|
||||
private static final List<String> anyNumberCardsAllowed = new ArrayList<>(Arrays.asList(
|
||||
"Relentless Rats", "Shadowborn Apostle", "Rat Colony", "Persistent Petitioners", "Seven Dwarves"
|
||||
"Relentless Rats", "Shadowborn Apostle", "Rat Colony",
|
||||
"Persistent Petitioners", "Seven Dwarves", "Dragon's Approach"
|
||||
));
|
||||
protected static final List<String> basicLandNames = new ArrayList<>(Arrays.asList(
|
||||
"Forest", "Island", "Mountain", "Swamp", "Plains", "Wastes", "Snow-Covered Forest",
|
||||
|
|
Loading…
Reference in a new issue