mirror of
https://github.com/correl/mage.git
synced 2025-01-12 19:25:44 +00:00
[MID] Implemented Path to the Festival
This commit is contained in:
parent
0d49a91a6f
commit
05e80e3a02
2 changed files with 64 additions and 0 deletions
63
Mage.Sets/src/mage/cards/p/PathToTheFestival.java
Normal file
63
Mage.Sets/src/mage/cards/p/PathToTheFestival.java
Normal file
|
@ -0,0 +1,63 @@
|
|||
package mage.cards.p;
|
||||
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.condition.Condition;
|
||||
import mage.abilities.costs.mana.ManaCostsImpl;
|
||||
import mage.abilities.decorator.ConditionalOneShotEffect;
|
||||
import mage.abilities.dynamicvalue.DynamicValue;
|
||||
import mage.abilities.dynamicvalue.common.DomainValue;
|
||||
import mage.abilities.effects.common.search.SearchLibraryPutInPlayEffect;
|
||||
import mage.abilities.effects.keyword.ScryEffect;
|
||||
import mage.abilities.hint.common.DomainHint;
|
||||
import mage.abilities.keyword.FlashbackAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.TimingRule;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.game.Game;
|
||||
import mage.target.common.TargetCardInLibrary;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
public final class PathToTheFestival extends CardImpl {
|
||||
|
||||
public PathToTheFestival(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{2}{G}");
|
||||
|
||||
// Search your library for a basic land card, put that card onto the battlefield tapped, then shuffle. Then if there are three or more basic land types among lands you control, scry 1.
|
||||
this.getSpellAbility().addEffect(new SearchLibraryPutInPlayEffect(
|
||||
new TargetCardInLibrary(StaticFilters.FILTER_CARD_BASIC_LAND), true
|
||||
));
|
||||
this.getSpellAbility().addEffect(new ConditionalOneShotEffect(
|
||||
new ScryEffect(1), PathToTheFestivalCondition.instance,
|
||||
"Then if there are three or more basic land types among lands you control, scry 1"
|
||||
));
|
||||
this.getSpellAbility().addHint(DomainHint.instance);
|
||||
|
||||
// Flashback {4}{G}
|
||||
this.addAbility(new FlashbackAbility(new ManaCostsImpl<>("{4}{G}"), TimingRule.SORCERY));
|
||||
}
|
||||
|
||||
private PathToTheFestival(final PathToTheFestival card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public PathToTheFestival copy() {
|
||||
return new PathToTheFestival(this);
|
||||
}
|
||||
}
|
||||
|
||||
enum PathToTheFestivalCondition implements Condition {
|
||||
instance;
|
||||
private static final DynamicValue xValue = new DomainValue();
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
return xValue.calculate(game, source, null) >= 3;
|
||||
}
|
||||
}
|
|
@ -202,6 +202,7 @@ public final class InnistradMidnightHunt extends ExpansionSet {
|
|||
cards.add(new SetCardInfo("Overgrown Farmland", 265, Rarity.RARE, mage.cards.o.OvergrownFarmland.class));
|
||||
cards.add(new SetCardInfo("Overwhelmed Archivist", 68, Rarity.UNCOMMON, mage.cards.o.OverwhelmedArchivist.class));
|
||||
cards.add(new SetCardInfo("Pack's Betrayal", 153, Rarity.COMMON, mage.cards.p.PacksBetrayal.class));
|
||||
cards.add(new SetCardInfo("Path to the Festival", 191, Rarity.COMMON, mage.cards.p.PathToTheFestival.class));
|
||||
cards.add(new SetCardInfo("Patrician Geist", 69, Rarity.RARE, mage.cards.p.PatricianGeist.class));
|
||||
cards.add(new SetCardInfo("Pestilent Wolf", 192, Rarity.COMMON, mage.cards.p.PestilentWolf.class));
|
||||
cards.add(new SetCardInfo("Phantom Carriage", 70, Rarity.UNCOMMON, mage.cards.p.PhantomCarriage.class));
|
||||
|
|
Loading…
Reference in a new issue