mirror of
https://github.com/magefree/mage.git
synced 2025-12-20 10:40:06 -08:00
[EOE] Implement Extinguisher Battleship
This commit is contained in:
parent
227391b2d4
commit
00df3feccd
17 changed files with 159 additions and 270 deletions
|
|
@ -9,8 +9,7 @@ import mage.cards.CardImpl;
|
||||||
import mage.cards.CardSetInfo;
|
import mage.cards.CardSetInfo;
|
||||||
import mage.constants.CardType;
|
import mage.constants.CardType;
|
||||||
import mage.constants.SubType;
|
import mage.constants.SubType;
|
||||||
import mage.filter.FilterPermanent;
|
import mage.filter.StaticFilters;
|
||||||
import mage.filter.predicate.Predicates;
|
|
||||||
import mage.target.TargetPermanent;
|
import mage.target.TargetPermanent;
|
||||||
|
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
|
|
@ -20,12 +19,6 @@ import java.util.UUID;
|
||||||
*/
|
*/
|
||||||
public final class AstralDragon extends CardImpl {
|
public final class AstralDragon extends CardImpl {
|
||||||
|
|
||||||
private static final FilterPermanent filter = new FilterPermanent("noncreature permanent");
|
|
||||||
|
|
||||||
static {
|
|
||||||
filter.add(Predicates.not(CardType.CREATURE.getPredicate()));
|
|
||||||
}
|
|
||||||
|
|
||||||
public AstralDragon(UUID ownerId, CardSetInfo setInfo) {
|
public AstralDragon(UUID ownerId, CardSetInfo setInfo) {
|
||||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{6}{U}{U}");
|
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{6}{U}{U}");
|
||||||
|
|
||||||
|
|
@ -37,14 +30,13 @@ public final class AstralDragon extends CardImpl {
|
||||||
this.addAbility(FlyingAbility.getInstance());
|
this.addAbility(FlyingAbility.getInstance());
|
||||||
|
|
||||||
// Project Image — When Astral Dragon enters the battlefield, create two tokens that are copies of target noncreature permanent, except they're 3/3 Dragon creatures in addition to their other types, and they have flying.
|
// Project Image — When Astral Dragon enters the battlefield, create two tokens that are copies of target noncreature permanent, except they're 3/3 Dragon creatures in addition to their other types, and they have flying.
|
||||||
CreateTokenCopyTargetEffect effect = new CreateTokenCopyTargetEffect(
|
Ability ability = new EntersBattlefieldTriggeredAbility(new CreateTokenCopyTargetEffect(
|
||||||
null, CardType.CREATURE, false, 2, false,
|
null, CardType.CREATURE, false, 2, false,
|
||||||
false, null, 3, 3, true);
|
false, null, 3, 3, true
|
||||||
effect.setText("create two tokens that are copies of target noncreature permanent, " +
|
).withAdditionalSubType(SubType.DRAGON)
|
||||||
"except they're 3/3 Dragon creatures in addition to their other types, and they have flying");
|
.setText("create two tokens that are copies of target noncreature permanent, " +
|
||||||
effect.withAdditionalSubType(SubType.DRAGON);
|
"except they're 3/3 Dragon creatures in addition to their other types, and they have flying"));
|
||||||
Ability ability = new EntersBattlefieldTriggeredAbility(effect);
|
ability.addTarget(new TargetPermanent(StaticFilters.FILTER_PERMANENT_NON_CREATURE));
|
||||||
ability.addTarget(new TargetPermanent(filter));
|
|
||||||
this.addAbility(ability.withFlavorWord("Project Image"));
|
this.addAbility(ability.withFlavorWord("Project Image"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,34 +1,25 @@
|
||||||
|
|
||||||
package mage.cards.b;
|
package mage.cards.b;
|
||||||
|
|
||||||
import java.util.UUID;
|
|
||||||
import mage.abilities.effects.common.DestroyTargetEffect;
|
import mage.abilities.effects.common.DestroyTargetEffect;
|
||||||
import mage.cards.CardImpl;
|
import mage.cards.CardImpl;
|
||||||
import mage.cards.CardSetInfo;
|
import mage.cards.CardSetInfo;
|
||||||
import mage.constants.CardType;
|
import mage.constants.CardType;
|
||||||
import mage.filter.FilterPermanent;
|
import mage.filter.StaticFilters;
|
||||||
import mage.filter.predicate.Predicates;
|
|
||||||
import mage.target.TargetPermanent;
|
import mage.target.TargetPermanent;
|
||||||
|
|
||||||
|
import java.util.UUID;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
|
||||||
* @author North
|
* @author North
|
||||||
*/
|
*/
|
||||||
public final class Bramblecrush extends CardImpl {
|
public final class Bramblecrush extends CardImpl {
|
||||||
|
|
||||||
private static final FilterPermanent filter = new FilterPermanent("noncreature permanent");
|
|
||||||
|
|
||||||
static {
|
|
||||||
filter.add(Predicates.not(CardType.CREATURE.getPredicate()));
|
|
||||||
}
|
|
||||||
|
|
||||||
public Bramblecrush(UUID ownerId, CardSetInfo setInfo) {
|
public Bramblecrush(UUID ownerId, CardSetInfo setInfo) {
|
||||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{2}{G}{G}");
|
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{2}{G}{G}");
|
||||||
|
|
||||||
|
|
||||||
// Destroy target noncreature permanent.
|
// Destroy target noncreature permanent.
|
||||||
this.getSpellAbility().addTarget(new TargetPermanent(filter));
|
|
||||||
this.getSpellAbility().addEffect(new DestroyTargetEffect());
|
this.getSpellAbility().addEffect(new DestroyTargetEffect());
|
||||||
|
this.getSpellAbility().addTarget(new TargetPermanent(StaticFilters.FILTER_PERMANENT_NON_CREATURE));
|
||||||
}
|
}
|
||||||
|
|
||||||
private Bramblecrush(final Bramblecrush card) {
|
private Bramblecrush(final Bramblecrush card) {
|
||||||
|
|
|
||||||
|
|
@ -1,41 +1,29 @@
|
||||||
|
|
||||||
package mage.cards.b;
|
package mage.cards.b;
|
||||||
|
|
||||||
import java.util.UUID;
|
|
||||||
import mage.MageInt;
|
import mage.MageInt;
|
||||||
import mage.abilities.Ability;
|
import mage.abilities.Ability;
|
||||||
import mage.abilities.Mode;
|
import mage.abilities.Mode;
|
||||||
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
|
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
|
||||||
import mage.abilities.effects.OneShotEffect;
|
import mage.abilities.effects.common.PutOnLibraryTargetEffect;
|
||||||
import mage.abilities.effects.common.search.SearchLibraryPutOnLibraryEffect;
|
import mage.abilities.effects.common.search.SearchLibraryPutOnLibraryEffect;
|
||||||
import mage.cards.CardImpl;
|
import mage.cards.CardImpl;
|
||||||
import mage.cards.CardSetInfo;
|
import mage.cards.CardSetInfo;
|
||||||
import mage.constants.CardType;
|
import mage.constants.CardType;
|
||||||
import mage.constants.Outcome;
|
|
||||||
import mage.constants.SubType;
|
import mage.constants.SubType;
|
||||||
import mage.filter.FilterPermanent;
|
import mage.filter.StaticFilters;
|
||||||
import mage.filter.common.FilterCreatureCard;
|
import mage.filter.common.FilterCreatureCard;
|
||||||
import mage.filter.predicate.Predicates;
|
|
||||||
import mage.game.Game;
|
|
||||||
import mage.game.permanent.Permanent;
|
|
||||||
import mage.players.Player;
|
|
||||||
import mage.target.TargetPermanent;
|
import mage.target.TargetPermanent;
|
||||||
import mage.target.common.TargetCardInLibrary;
|
import mage.target.common.TargetCardInLibrary;
|
||||||
|
|
||||||
|
import java.util.UUID;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
|
||||||
* @author North
|
* @author North
|
||||||
*/
|
*/
|
||||||
public final class BrutalizerExarch extends CardImpl {
|
public final class BrutalizerExarch extends CardImpl {
|
||||||
|
|
||||||
private static final FilterPermanent filter = new FilterPermanent("noncreature permanent");
|
|
||||||
|
|
||||||
static {
|
|
||||||
filter.add(Predicates.not(CardType.CREATURE.getPredicate()));
|
|
||||||
}
|
|
||||||
|
|
||||||
public BrutalizerExarch(UUID ownerId, CardSetInfo setInfo) {
|
public BrutalizerExarch(UUID ownerId, CardSetInfo setInfo) {
|
||||||
super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{5}{G}");
|
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{5}{G}");
|
||||||
this.subtype.add(SubType.PHYREXIAN);
|
this.subtype.add(SubType.PHYREXIAN);
|
||||||
this.subtype.add(SubType.CLERIC);
|
this.subtype.add(SubType.CLERIC);
|
||||||
|
|
||||||
|
|
@ -44,12 +32,13 @@ public final class BrutalizerExarch extends CardImpl {
|
||||||
|
|
||||||
// When Brutalizer Exarch enters the battlefield, choose one
|
// When Brutalizer Exarch enters the battlefield, choose one
|
||||||
// - Search your library for a creature card, reveal it, then shuffle your library and put that card on top of it;
|
// - Search your library for a creature card, reveal it, then shuffle your library and put that card on top of it;
|
||||||
TargetCardInLibrary target = new TargetCardInLibrary(new FilterCreatureCard("a creature card"));
|
Ability ability = new EntersBattlefieldTriggeredAbility(new SearchLibraryPutOnLibraryEffect(
|
||||||
Ability ability = new EntersBattlefieldTriggeredAbility(new SearchLibraryPutOnLibraryEffect(target, true), false);
|
new TargetCardInLibrary(new FilterCreatureCard("a creature card")), true
|
||||||
|
), false);
|
||||||
|
|
||||||
// or put target noncreature permanent on the bottom of its owner's library.
|
// or put target noncreature permanent on the bottom of its owner's library.
|
||||||
Mode mode = new Mode(new BrutalizerExarchEffect2());
|
ability.addMode(new Mode(new PutOnLibraryTargetEffect(false))
|
||||||
mode.addTarget(new TargetPermanent(filter));
|
.addTarget(new TargetPermanent(StaticFilters.FILTER_PERMANENT_NON_CREATURE)));
|
||||||
ability.addMode(mode);
|
|
||||||
this.addAbility(ability);
|
this.addAbility(ability);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -62,30 +51,3 @@ public final class BrutalizerExarch extends CardImpl {
|
||||||
return new BrutalizerExarch(this);
|
return new BrutalizerExarch(this);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class BrutalizerExarchEffect2 extends OneShotEffect {
|
|
||||||
|
|
||||||
public BrutalizerExarchEffect2() {
|
|
||||||
super(Outcome.Removal);
|
|
||||||
this.staticText = "put target noncreature permanent on the bottom of its owner's library";
|
|
||||||
}
|
|
||||||
|
|
||||||
private BrutalizerExarchEffect2(final BrutalizerExarchEffect2 effect) {
|
|
||||||
super(effect);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public BrutalizerExarchEffect2 copy() {
|
|
||||||
return new BrutalizerExarchEffect2(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean apply(Game game, Ability source) {
|
|
||||||
Permanent permanent = game.getPermanent(source.getFirstTarget());
|
|
||||||
Player controller = game.getPlayer(source.getControllerId());
|
|
||||||
if (permanent != null && controller != null) {
|
|
||||||
return controller.putCardsOnBottomOfLibrary(permanent, game, source);
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,5 @@
|
||||||
|
|
||||||
package mage.cards.c;
|
package mage.cards.c;
|
||||||
|
|
||||||
import java.util.UUID;
|
|
||||||
import mage.abilities.Ability;
|
import mage.abilities.Ability;
|
||||||
import mage.abilities.effects.Effect;
|
import mage.abilities.effects.Effect;
|
||||||
import mage.abilities.effects.OneShotEffect;
|
import mage.abilities.effects.OneShotEffect;
|
||||||
|
|
@ -10,8 +8,7 @@ import mage.cards.CardImpl;
|
||||||
import mage.cards.CardSetInfo;
|
import mage.cards.CardSetInfo;
|
||||||
import mage.constants.CardType;
|
import mage.constants.CardType;
|
||||||
import mage.constants.Outcome;
|
import mage.constants.Outcome;
|
||||||
import mage.filter.FilterPermanent;
|
import mage.filter.StaticFilters;
|
||||||
import mage.filter.predicate.Predicates;
|
|
||||||
import mage.game.Game;
|
import mage.game.Game;
|
||||||
import mage.game.permanent.Permanent;
|
import mage.game.permanent.Permanent;
|
||||||
import mage.game.stack.Spell;
|
import mage.game.stack.Spell;
|
||||||
|
|
@ -19,24 +16,19 @@ import mage.players.Player;
|
||||||
import mage.target.TargetPermanent;
|
import mage.target.TargetPermanent;
|
||||||
import mage.target.targetpointer.FixedTarget;
|
import mage.target.targetpointer.FixedTarget;
|
||||||
|
|
||||||
|
import java.util.UUID;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
|
||||||
* @author TheElk801
|
* @author TheElk801
|
||||||
*/
|
*/
|
||||||
public final class ChainOfAcid extends CardImpl {
|
public final class ChainOfAcid extends CardImpl {
|
||||||
|
|
||||||
private static final FilterPermanent filter = new FilterPermanent("noncreature permanent");
|
|
||||||
|
|
||||||
static {
|
|
||||||
filter.add(Predicates.not(CardType.CREATURE.getPredicate()));
|
|
||||||
}
|
|
||||||
|
|
||||||
public ChainOfAcid(UUID ownerId, CardSetInfo setInfo) {
|
public ChainOfAcid(UUID ownerId, CardSetInfo setInfo) {
|
||||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{3}{G}");
|
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{3}{G}");
|
||||||
|
|
||||||
// Destroy target noncreature permanent. Then that permanent's controller may copy this spell and may choose a new target for that copy.
|
// Destroy target noncreature permanent. Then that permanent's controller may copy this spell and may choose a new target for that copy.
|
||||||
this.getSpellAbility().addEffect(new ChainOfAcidEffect());
|
this.getSpellAbility().addEffect(new ChainOfAcidEffect());
|
||||||
this.getSpellAbility().addTarget(new TargetPermanent(filter));
|
this.getSpellAbility().addTarget(new TargetPermanent(StaticFilters.FILTER_PERMANENT_NON_CREATURE));
|
||||||
}
|
}
|
||||||
|
|
||||||
private ChainOfAcid(final ChainOfAcid card) {
|
private ChainOfAcid(final ChainOfAcid card) {
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,6 @@
|
||||||
|
|
||||||
package mage.cards.d;
|
package mage.cards.d;
|
||||||
|
|
||||||
import java.util.UUID;
|
|
||||||
import mage.MageInt;
|
import mage.MageInt;
|
||||||
import mage.abilities.Ability;
|
import mage.abilities.Ability;
|
||||||
import mage.abilities.common.DiesSourceTriggeredAbility;
|
import mage.abilities.common.DiesSourceTriggeredAbility;
|
||||||
|
|
@ -11,32 +10,28 @@ import mage.cards.CardImpl;
|
||||||
import mage.cards.CardSetInfo;
|
import mage.cards.CardSetInfo;
|
||||||
import mage.constants.CardType;
|
import mage.constants.CardType;
|
||||||
import mage.constants.SubType;
|
import mage.constants.SubType;
|
||||||
import mage.filter.FilterPermanent;
|
import mage.filter.StaticFilters;
|
||||||
import mage.filter.predicate.Predicates;
|
|
||||||
import mage.target.TargetPermanent;
|
import mage.target.TargetPermanent;
|
||||||
|
|
||||||
|
import java.util.UUID;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
|
||||||
* @author fireshoes
|
* @author fireshoes
|
||||||
*/
|
*/
|
||||||
public final class DestructorDragon extends CardImpl {
|
public final class DestructorDragon extends CardImpl {
|
||||||
|
|
||||||
private static final FilterPermanent filter = new FilterPermanent("noncreature permanent");
|
|
||||||
static {
|
|
||||||
filter.add(Predicates.not(CardType.CREATURE.getPredicate()));
|
|
||||||
}
|
|
||||||
|
|
||||||
public DestructorDragon(UUID ownerId, CardSetInfo setInfo) {
|
public DestructorDragon(UUID ownerId, CardSetInfo setInfo) {
|
||||||
super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{4}{G}{G}");
|
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{4}{G}{G}");
|
||||||
this.subtype.add(SubType.DRAGON);
|
this.subtype.add(SubType.DRAGON);
|
||||||
this.power = new MageInt(4);
|
this.power = new MageInt(4);
|
||||||
this.toughness = new MageInt(4);
|
this.toughness = new MageInt(4);
|
||||||
|
|
||||||
// Flying
|
// Flying
|
||||||
this.addAbility(FlyingAbility.getInstance());
|
this.addAbility(FlyingAbility.getInstance());
|
||||||
|
|
||||||
// When Destructor Dragon dies, destroy target noncreature permanent.
|
// When Destructor Dragon dies, destroy target noncreature permanent.
|
||||||
Ability ability = new DiesSourceTriggeredAbility(new DestroyTargetEffect(), false);
|
Ability ability = new DiesSourceTriggeredAbility(new DestroyTargetEffect());
|
||||||
ability.addTarget(new TargetPermanent(filter));
|
ability.addTarget(new TargetPermanent(StaticFilters.FILTER_PERMANENT_NON_CREATURE));
|
||||||
this.addAbility(ability);
|
this.addAbility(ability);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
57
Mage.Sets/src/mage/cards/e/ExtinguisherBattleship.java
Normal file
57
Mage.Sets/src/mage/cards/e/ExtinguisherBattleship.java
Normal file
|
|
@ -0,0 +1,57 @@
|
||||||
|
package mage.cards.e;
|
||||||
|
|
||||||
|
import mage.abilities.Ability;
|
||||||
|
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
|
||||||
|
import mage.abilities.effects.common.DamageAllEffect;
|
||||||
|
import mage.abilities.effects.common.DestroyTargetEffect;
|
||||||
|
import mage.abilities.keyword.FlyingAbility;
|
||||||
|
import mage.abilities.keyword.StationAbility;
|
||||||
|
import mage.abilities.keyword.StationLevelAbility;
|
||||||
|
import mage.abilities.keyword.TrampleAbility;
|
||||||
|
import mage.cards.CardImpl;
|
||||||
|
import mage.cards.CardSetInfo;
|
||||||
|
import mage.constants.CardType;
|
||||||
|
import mage.constants.SubType;
|
||||||
|
import mage.filter.StaticFilters;
|
||||||
|
import mage.target.TargetPermanent;
|
||||||
|
|
||||||
|
import java.util.UUID;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author TheElk801
|
||||||
|
*/
|
||||||
|
public final class ExtinguisherBattleship extends CardImpl {
|
||||||
|
|
||||||
|
public ExtinguisherBattleship(UUID ownerId, CardSetInfo setInfo) {
|
||||||
|
super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT}, "{8}");
|
||||||
|
|
||||||
|
this.subtype.add(SubType.SPACECRAFT);
|
||||||
|
|
||||||
|
// When this Spacecraft enters, destroy target noncreature permanent. Then this Spacecraft deals 4 damage to each creature.
|
||||||
|
Ability ability = new EntersBattlefieldTriggeredAbility(new DestroyTargetEffect());
|
||||||
|
ability.addEffect(new DamageAllEffect(4, StaticFilters.FILTER_PERMANENT_CREATURE).concatBy("Then"));
|
||||||
|
ability.addTarget(new TargetPermanent(StaticFilters.FILTER_PERMANENT_NON_CREATURE));
|
||||||
|
this.addAbility(ability);
|
||||||
|
|
||||||
|
// Station
|
||||||
|
this.addAbility(new StationAbility());
|
||||||
|
|
||||||
|
// STATION 5+
|
||||||
|
// Flying
|
||||||
|
// Trample
|
||||||
|
// 10/10
|
||||||
|
this.addAbility(new StationLevelAbility(5)
|
||||||
|
.withLevelAbility(FlyingAbility.getInstance())
|
||||||
|
.withLevelAbility(TrampleAbility.getInstance())
|
||||||
|
.withPT(10, 10));
|
||||||
|
}
|
||||||
|
|
||||||
|
private ExtinguisherBattleship(final ExtinguisherBattleship card) {
|
||||||
|
super(card);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ExtinguisherBattleship copy() {
|
||||||
|
return new ExtinguisherBattleship(this);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
package mage.cards.m;
|
package mage.cards.m;
|
||||||
|
|
||||||
import mage.MageInt;
|
import mage.MageInt;
|
||||||
|
import mage.abilities.Ability;
|
||||||
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
|
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
|
||||||
import mage.abilities.condition.common.KickedCondition;
|
import mage.abilities.condition.common.KickedCondition;
|
||||||
import mage.abilities.effects.common.DestroyTargetEffect;
|
import mage.abilities.effects.common.DestroyTargetEffect;
|
||||||
|
|
@ -9,26 +10,18 @@ import mage.cards.CardImpl;
|
||||||
import mage.cards.CardSetInfo;
|
import mage.cards.CardSetInfo;
|
||||||
import mage.constants.CardType;
|
import mage.constants.CardType;
|
||||||
import mage.constants.SubType;
|
import mage.constants.SubType;
|
||||||
import mage.filter.FilterPermanent;
|
import mage.filter.StaticFilters;
|
||||||
import mage.filter.predicate.Predicates;
|
|
||||||
import mage.target.TargetPermanent;
|
import mage.target.TargetPermanent;
|
||||||
|
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
|
||||||
* @author North
|
* @author North
|
||||||
*/
|
*/
|
||||||
public final class MoldShambler extends CardImpl {
|
public final class MoldShambler extends CardImpl {
|
||||||
|
|
||||||
private static final FilterPermanent filter = new FilterPermanent("noncreature permanent");
|
|
||||||
|
|
||||||
static {
|
|
||||||
filter.add(Predicates.not(CardType.CREATURE.getPredicate()));
|
|
||||||
}
|
|
||||||
|
|
||||||
public MoldShambler(UUID ownerId, CardSetInfo setInfo) {
|
public MoldShambler(UUID ownerId, CardSetInfo setInfo) {
|
||||||
super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{3}{G}");
|
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{3}{G}");
|
||||||
this.subtype.add(SubType.FUNGUS);
|
this.subtype.add(SubType.FUNGUS);
|
||||||
this.subtype.add(SubType.BEAST);
|
this.subtype.add(SubType.BEAST);
|
||||||
|
|
||||||
|
|
@ -39,9 +32,9 @@ public final class MoldShambler extends CardImpl {
|
||||||
this.addAbility(new KickerAbility("{1}{G}"));
|
this.addAbility(new KickerAbility("{1}{G}"));
|
||||||
|
|
||||||
// When Mold Shambler enters the battlefield, if it was kicked, destroy target noncreature permanent.
|
// When Mold Shambler enters the battlefield, if it was kicked, destroy target noncreature permanent.
|
||||||
EntersBattlefieldTriggeredAbility ability = new EntersBattlefieldTriggeredAbility(new DestroyTargetEffect(), false);
|
Ability ability = new EntersBattlefieldTriggeredAbility(new DestroyTargetEffect()).withInterveningIf(KickedCondition.ONCE);
|
||||||
ability.addTarget(new TargetPermanent(filter));
|
ability.addTarget(new TargetPermanent(StaticFilters.FILTER_PERMANENT_NON_CREATURE));
|
||||||
this.addAbility(ability.withInterveningIf(KickedCondition.ONCE));
|
this.addAbility(ability);
|
||||||
}
|
}
|
||||||
|
|
||||||
private MoldShambler(final MoldShambler card) {
|
private MoldShambler(final MoldShambler card) {
|
||||||
|
|
|
||||||
|
|
@ -10,8 +10,7 @@ import mage.cards.CardImpl;
|
||||||
import mage.cards.CardSetInfo;
|
import mage.cards.CardSetInfo;
|
||||||
import mage.constants.CardType;
|
import mage.constants.CardType;
|
||||||
import mage.constants.SubType;
|
import mage.constants.SubType;
|
||||||
import mage.filter.FilterPermanent;
|
import mage.filter.StaticFilters;
|
||||||
import mage.filter.predicate.Predicates;
|
|
||||||
import mage.target.TargetPermanent;
|
import mage.target.TargetPermanent;
|
||||||
|
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
|
|
@ -21,12 +20,6 @@ import java.util.UUID;
|
||||||
*/
|
*/
|
||||||
public final class NessianDemolok extends CardImpl {
|
public final class NessianDemolok extends CardImpl {
|
||||||
|
|
||||||
private static final FilterPermanent filter = new FilterPermanent("noncreature permanent");
|
|
||||||
|
|
||||||
static {
|
|
||||||
filter.add(Predicates.not(CardType.CREATURE.getPredicate()));
|
|
||||||
}
|
|
||||||
|
|
||||||
public NessianDemolok(UUID ownerId, CardSetInfo setInfo) {
|
public NessianDemolok(UUID ownerId, CardSetInfo setInfo) {
|
||||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{3}{G}{G}");
|
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{3}{G}{G}");
|
||||||
this.subtype.add(SubType.BEAST);
|
this.subtype.add(SubType.BEAST);
|
||||||
|
|
@ -40,7 +33,7 @@ public final class NessianDemolok extends CardImpl {
|
||||||
// When Nessian Demolok enters the battlefield, if tribute wasn't paid, destroy target noncreature permanent.
|
// When Nessian Demolok enters the battlefield, if tribute wasn't paid, destroy target noncreature permanent.
|
||||||
Ability ability = new EntersBattlefieldTriggeredAbility(new DestroyTargetEffect())
|
Ability ability = new EntersBattlefieldTriggeredAbility(new DestroyTargetEffect())
|
||||||
.withInterveningIf(TributeNotPaidCondition.instance);
|
.withInterveningIf(TributeNotPaidCondition.instance);
|
||||||
ability.addTarget(new TargetPermanent(filter));
|
ability.addTarget(new TargetPermanent(StaticFilters.FILTER_PERMANENT_NON_CREATURE));
|
||||||
this.addAbility(ability);
|
this.addAbility(ability);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,5 @@
|
||||||
|
|
||||||
package mage.cards.n;
|
package mage.cards.n;
|
||||||
|
|
||||||
import java.util.UUID;
|
|
||||||
import mage.abilities.LoyaltyAbility;
|
import mage.abilities.LoyaltyAbility;
|
||||||
import mage.abilities.effects.common.DamageTargetEffect;
|
import mage.abilities.effects.common.DamageTargetEffect;
|
||||||
import mage.abilities.effects.common.DestroyTargetEffect;
|
import mage.abilities.effects.common.DestroyTargetEffect;
|
||||||
|
|
@ -11,27 +9,22 @@ import mage.abilities.effects.common.discard.DiscardTargetEffect;
|
||||||
import mage.cards.CardImpl;
|
import mage.cards.CardImpl;
|
||||||
import mage.cards.CardSetInfo;
|
import mage.cards.CardSetInfo;
|
||||||
import mage.constants.CardType;
|
import mage.constants.CardType;
|
||||||
import mage.constants.SubType;
|
|
||||||
import mage.constants.Duration;
|
import mage.constants.Duration;
|
||||||
|
import mage.constants.SubType;
|
||||||
import mage.constants.SuperType;
|
import mage.constants.SuperType;
|
||||||
import mage.filter.FilterPermanent;
|
import mage.filter.FilterPermanent;
|
||||||
import mage.filter.predicate.Predicates;
|
import mage.filter.StaticFilters;
|
||||||
import mage.target.TargetPermanent;
|
import mage.target.TargetPermanent;
|
||||||
import mage.target.common.TargetCreaturePermanent;
|
import mage.target.common.TargetCreaturePermanent;
|
||||||
import mage.target.common.TargetPlayerOrPlaneswalker;
|
import mage.target.common.TargetPlayerOrPlaneswalker;
|
||||||
|
|
||||||
|
import java.util.UUID;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
|
||||||
* @author North
|
* @author North
|
||||||
*/
|
*/
|
||||||
public final class NicolBolasPlaneswalker extends CardImpl {
|
public final class NicolBolasPlaneswalker extends CardImpl {
|
||||||
|
|
||||||
private static final FilterPermanent filter = new FilterPermanent("noncreature permanent");
|
|
||||||
|
|
||||||
static {
|
|
||||||
filter.add(Predicates.not(CardType.CREATURE.getPredicate()));
|
|
||||||
}
|
|
||||||
|
|
||||||
public NicolBolasPlaneswalker(UUID ownerId, CardSetInfo setInfo) {
|
public NicolBolasPlaneswalker(UUID ownerId, CardSetInfo setInfo) {
|
||||||
super(ownerId, setInfo, new CardType[]{CardType.PLANESWALKER}, "{4}{U}{B}{B}{R}");
|
super(ownerId, setInfo, new CardType[]{CardType.PLANESWALKER}, "{4}{U}{B}{B}{R}");
|
||||||
this.supertype.add(SuperType.LEGENDARY);
|
this.supertype.add(SuperType.LEGENDARY);
|
||||||
|
|
@ -41,12 +34,14 @@ public final class NicolBolasPlaneswalker extends CardImpl {
|
||||||
|
|
||||||
// +3: Destroy target noncreature permanent.
|
// +3: Destroy target noncreature permanent.
|
||||||
LoyaltyAbility ability = new LoyaltyAbility(new DestroyTargetEffect(), 3);
|
LoyaltyAbility ability = new LoyaltyAbility(new DestroyTargetEffect(), 3);
|
||||||
ability.addTarget(new TargetPermanent(filter));
|
ability.addTarget(new TargetPermanent(StaticFilters.FILTER_PERMANENT_NON_CREATURE));
|
||||||
this.addAbility(ability);
|
this.addAbility(ability);
|
||||||
|
|
||||||
// -2: Gain control of target creature.
|
// -2: Gain control of target creature.
|
||||||
ability = new LoyaltyAbility(new GainControlTargetEffect(Duration.Custom), -2);
|
ability = new LoyaltyAbility(new GainControlTargetEffect(Duration.Custom), -2);
|
||||||
ability.addTarget(new TargetCreaturePermanent());
|
ability.addTarget(new TargetCreaturePermanent());
|
||||||
this.addAbility(ability);
|
this.addAbility(ability);
|
||||||
|
|
||||||
// -9: Nicol Bolas, Planeswalker deals 7 damage to target player. That player discards seven cards, then sacrifices seven permanents.
|
// -9: Nicol Bolas, Planeswalker deals 7 damage to target player. That player discards seven cards, then sacrifices seven permanents.
|
||||||
ability = new LoyaltyAbility(new DamageTargetEffect(7), -9);
|
ability = new LoyaltyAbility(new DamageTargetEffect(7), -9);
|
||||||
ability.addTarget(new TargetPlayerOrPlaneswalker());
|
ability.addTarget(new TargetPlayerOrPlaneswalker());
|
||||||
|
|
|
||||||
|
|
@ -1,62 +1,52 @@
|
||||||
package mage.cards.p;
|
package mage.cards.p;
|
||||||
|
|
||||||
import java.util.UUID;
|
|
||||||
import mage.abilities.Ability;
|
import mage.abilities.Ability;
|
||||||
import mage.abilities.Mode;
|
import mage.abilities.Mode;
|
||||||
import mage.abilities.effects.OneShotEffect;
|
import mage.abilities.effects.OneShotEffect;
|
||||||
import mage.abilities.effects.common.GainLifeTargetEffect;
|
import mage.abilities.effects.common.GainLifeTargetEffect;
|
||||||
import mage.abilities.effects.common.PutOnLibraryTargetEffect;
|
import mage.abilities.effects.common.PutOnLibraryTargetEffect;
|
||||||
import mage.abilities.effects.common.search.SearchLibraryPutInHandEffect;
|
import mage.abilities.effects.common.search.SearchLibraryPutInHandEffect;
|
||||||
import mage.cards.Card;
|
|
||||||
import mage.cards.CardImpl;
|
import mage.cards.CardImpl;
|
||||||
import mage.cards.CardSetInfo;
|
import mage.cards.CardSetInfo;
|
||||||
import mage.constants.CardType;
|
import mage.constants.CardType;
|
||||||
import mage.constants.Outcome;
|
import mage.constants.Outcome;
|
||||||
import mage.constants.Zone;
|
|
||||||
import mage.filter.FilterPermanent;
|
|
||||||
import mage.filter.StaticFilters;
|
import mage.filter.StaticFilters;
|
||||||
import mage.filter.predicate.Predicates;
|
|
||||||
import mage.game.Game;
|
import mage.game.Game;
|
||||||
import mage.players.Player;
|
import mage.players.Player;
|
||||||
import mage.target.Target;
|
|
||||||
import mage.target.TargetPermanent;
|
import mage.target.TargetPermanent;
|
||||||
import mage.target.TargetPlayer;
|
import mage.target.TargetPlayer;
|
||||||
import mage.target.common.TargetCardInLibrary;
|
import mage.target.common.TargetCardInLibrary;
|
||||||
|
|
||||||
|
import java.util.UUID;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
|
||||||
* @author LevelX2
|
* @author LevelX2
|
||||||
*/
|
*/
|
||||||
public final class PrimalCommand extends CardImpl {
|
public final class PrimalCommand extends CardImpl {
|
||||||
|
|
||||||
private static final FilterPermanent filterNonCreature = new FilterPermanent("noncreature permanent");
|
|
||||||
|
|
||||||
static {
|
|
||||||
filterNonCreature.add(Predicates.not(CardType.CREATURE.getPredicate()));
|
|
||||||
}
|
|
||||||
|
|
||||||
public PrimalCommand(UUID ownerId, CardSetInfo setInfo) {
|
public PrimalCommand(UUID ownerId, CardSetInfo setInfo) {
|
||||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{3}{G}{G}");
|
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{3}{G}{G}");
|
||||||
|
|
||||||
// Choose two -
|
// Choose two -
|
||||||
this.getSpellAbility().getModes().setMinModes(2);
|
this.getSpellAbility().getModes().setMinModes(2);
|
||||||
this.getSpellAbility().getModes().setMaxModes(2);
|
this.getSpellAbility().getModes().setMaxModes(2);
|
||||||
|
|
||||||
// Target player gains 7 life;
|
// Target player gains 7 life;
|
||||||
this.getSpellAbility().addEffect(new GainLifeTargetEffect(7));
|
this.getSpellAbility().addEffect(new GainLifeTargetEffect(7));
|
||||||
this.getSpellAbility().addTarget(new TargetPlayer());
|
this.getSpellAbility().addTarget(new TargetPlayer());
|
||||||
// or put target noncreature permanent on top of its owner's library;
|
|
||||||
Mode mode = new Mode(new PutOnLibraryTargetEffect(true));
|
|
||||||
Target target = new TargetPermanent(filterNonCreature);
|
|
||||||
mode.addTarget(target);
|
|
||||||
this.getSpellAbility().getModes().addMode(mode);
|
|
||||||
// or target player shuffles their graveyard into their library;
|
|
||||||
mode = new Mode(new PrimalCommandShuffleGraveyardEffect());
|
|
||||||
mode.addTarget(new TargetPlayer());
|
|
||||||
this.getSpellAbility().getModes().addMode(mode);
|
|
||||||
// or search your library for a creature card, reveal it, put it into your hand, then shuffle your library.
|
|
||||||
mode = new Mode(new SearchLibraryPutInHandEffect(new TargetCardInLibrary(StaticFilters.FILTER_CARD_CREATURE), true));
|
|
||||||
this.getSpellAbility().getModes().addMode(mode);
|
|
||||||
|
|
||||||
|
// or put target noncreature permanent on top of its owner's library;
|
||||||
|
this.getSpellAbility().getModes().addMode(new Mode(new PutOnLibraryTargetEffect(true))
|
||||||
|
.addTarget(new TargetPermanent(StaticFilters.FILTER_PERMANENT_NON_CREATURE)));
|
||||||
|
|
||||||
|
// or target player shuffles their graveyard into their library;
|
||||||
|
this.getSpellAbility().getModes().addMode(new Mode(new PrimalCommandShuffleGraveyardEffect())
|
||||||
|
.addTarget(new TargetPlayer()));
|
||||||
|
|
||||||
|
// or search your library for a creature card, reveal it, put it into your hand, then shuffle your library.
|
||||||
|
this.getSpellAbility().getModes().addMode(new Mode(new SearchLibraryPutInHandEffect(
|
||||||
|
new TargetCardInLibrary(StaticFilters.FILTER_CARD_CREATURE), true
|
||||||
|
)));
|
||||||
}
|
}
|
||||||
|
|
||||||
private PrimalCommand(final PrimalCommand card) {
|
private PrimalCommand(final PrimalCommand card) {
|
||||||
|
|
@ -87,14 +77,8 @@ class PrimalCommandShuffleGraveyardEffect extends OneShotEffect {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean apply(Game game, Ability source) {
|
public boolean apply(Game game, Ability source) {
|
||||||
Player player = game.getPlayer(source.getFirstTarget());
|
Player player = game.getPlayer(getTargetPointer().getFirst(game, source));
|
||||||
if (player != null) {
|
player.shuffleCardsToLibrary(player.getGraveyard(), game, source);
|
||||||
for (Card card : player.getGraveyard().getCards(game)) {
|
|
||||||
player.moveCardToLibraryWithInfo(card, source, game, Zone.GRAVEYARD, true, true);
|
|
||||||
}
|
|
||||||
player.shuffleLibrary(source, game);
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
|
|
||||||
package mage.cards.r;
|
package mage.cards.r;
|
||||||
|
|
||||||
|
import mage.abilities.condition.Condition;
|
||||||
import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition;
|
import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition;
|
||||||
import mage.abilities.decorator.ConditionalOneShotEffect;
|
import mage.abilities.decorator.ConditionalOneShotEffect;
|
||||||
import mage.abilities.effects.common.DestroyTargetEffect;
|
import mage.abilities.effects.common.DestroyTargetEffect;
|
||||||
|
|
@ -9,38 +9,32 @@ import mage.cards.CardImpl;
|
||||||
import mage.cards.CardSetInfo;
|
import mage.cards.CardSetInfo;
|
||||||
import mage.constants.CardType;
|
import mage.constants.CardType;
|
||||||
import mage.constants.SubType;
|
import mage.constants.SubType;
|
||||||
import mage.filter.FilterPermanent;
|
import mage.filter.StaticFilters;
|
||||||
import mage.filter.predicate.Predicates;
|
import mage.filter.common.FilterControlledPermanent;
|
||||||
import mage.target.TargetPermanent;
|
import mage.target.TargetPermanent;
|
||||||
|
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
|
||||||
* @author Wehk
|
* @author Wehk
|
||||||
*/
|
*/
|
||||||
public final class Rootgrapple extends CardImpl {
|
public final class Rootgrapple extends CardImpl {
|
||||||
|
|
||||||
private static final FilterPermanent filterNoncreature = new FilterPermanent("noncreature permanent");
|
private static final Condition condition = new PermanentsOnTheBattlefieldCondition(new FilterControlledPermanent(SubType.TREEFOLK));
|
||||||
private static final FilterPermanent filterTreefolk = new FilterPermanent("If you control a Treefolk,");
|
|
||||||
|
|
||||||
static {
|
|
||||||
filterNoncreature.add(Predicates.not(CardType.CREATURE.getPredicate()));
|
|
||||||
filterTreefolk.add(SubType.TREEFOLK.getPredicate());
|
|
||||||
}
|
|
||||||
|
|
||||||
public Rootgrapple(UUID ownerId, CardSetInfo setInfo) {
|
public Rootgrapple(UUID ownerId, CardSetInfo setInfo) {
|
||||||
super(ownerId,setInfo,new CardType[]{CardType.KINDRED,CardType.INSTANT},"{4}{G}");
|
super(ownerId, setInfo, new CardType[]{CardType.KINDRED, CardType.INSTANT}, "{4}{G}");
|
||||||
this.subtype.add(SubType.TREEFOLK);
|
this.subtype.add(SubType.TREEFOLK);
|
||||||
|
|
||||||
// Destroy target noncreature permanent.
|
// Destroy target noncreature permanent.
|
||||||
this.getSpellAbility().addTarget(new TargetPermanent(filterNoncreature));
|
|
||||||
this.getSpellAbility().addEffect(new DestroyTargetEffect());
|
this.getSpellAbility().addEffect(new DestroyTargetEffect());
|
||||||
|
this.getSpellAbility().addTarget(new TargetPermanent(StaticFilters.FILTER_PERMANENT_NON_CREATURE));
|
||||||
|
|
||||||
// If you control a Treefolk, draw a card.
|
// If you control a Treefolk, draw a card.
|
||||||
this.getSpellAbility().addEffect(new ConditionalOneShotEffect(new DrawCardSourceControllerEffect(1),
|
this.getSpellAbility().addEffect(new ConditionalOneShotEffect(
|
||||||
new PermanentsOnTheBattlefieldCondition(filterTreefolk),
|
new DrawCardSourceControllerEffect(1), condition,
|
||||||
"If you control a Treefolk, draw a card"));
|
"If you control a Treefolk, draw a card"
|
||||||
|
));
|
||||||
}
|
}
|
||||||
|
|
||||||
private Rootgrapple(final Rootgrapple card) {
|
private Rootgrapple(final Rootgrapple card) {
|
||||||
|
|
|
||||||
|
|
@ -3,26 +3,17 @@ package mage.cards.s;
|
||||||
import mage.MageInt;
|
import mage.MageInt;
|
||||||
import mage.abilities.Ability;
|
import mage.abilities.Ability;
|
||||||
import mage.abilities.common.MutatesSourceTriggeredAbility;
|
import mage.abilities.common.MutatesSourceTriggeredAbility;
|
||||||
import mage.abilities.effects.Effect;
|
|
||||||
import mage.abilities.effects.OneShotEffect;
|
|
||||||
import mage.abilities.effects.common.CreateTokenControllerTargetEffect;
|
import mage.abilities.effects.common.CreateTokenControllerTargetEffect;
|
||||||
import mage.abilities.effects.common.CreateTokenTargetEffect;
|
|
||||||
import mage.abilities.effects.common.DestroyTargetEffect;
|
import mage.abilities.effects.common.DestroyTargetEffect;
|
||||||
import mage.abilities.keyword.MutateAbility;
|
import mage.abilities.keyword.MutateAbility;
|
||||||
import mage.abilities.keyword.TrampleAbility;
|
import mage.abilities.keyword.TrampleAbility;
|
||||||
import mage.cards.CardImpl;
|
import mage.cards.CardImpl;
|
||||||
import mage.cards.CardSetInfo;
|
import mage.cards.CardSetInfo;
|
||||||
import mage.constants.CardType;
|
import mage.constants.CardType;
|
||||||
import mage.constants.Outcome;
|
|
||||||
import mage.constants.SubType;
|
import mage.constants.SubType;
|
||||||
import mage.filter.FilterPermanent;
|
import mage.filter.StaticFilters;
|
||||||
import mage.filter.predicate.Predicates;
|
|
||||||
import mage.game.Game;
|
|
||||||
import mage.game.permanent.Permanent;
|
|
||||||
import mage.game.permanent.token.BeastToken;
|
import mage.game.permanent.token.BeastToken;
|
||||||
import mage.players.Player;
|
|
||||||
import mage.target.TargetPermanent;
|
import mage.target.TargetPermanent;
|
||||||
import mage.target.targetpointer.FixedTarget;
|
|
||||||
|
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
|
|
||||||
|
|
@ -31,12 +22,6 @@ import java.util.UUID;
|
||||||
*/
|
*/
|
||||||
public final class SawtuskDemolisher extends CardImpl {
|
public final class SawtuskDemolisher extends CardImpl {
|
||||||
|
|
||||||
private static final FilterPermanent filter = new FilterPermanent("noncreature permanent");
|
|
||||||
|
|
||||||
static {
|
|
||||||
filter.add(Predicates.not(CardType.CREATURE.getPredicate()));
|
|
||||||
}
|
|
||||||
|
|
||||||
public SawtuskDemolisher(UUID ownerId, CardSetInfo setInfo) {
|
public SawtuskDemolisher(UUID ownerId, CardSetInfo setInfo) {
|
||||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{4}{G}{G}");
|
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{4}{G}{G}");
|
||||||
|
|
||||||
|
|
@ -53,7 +38,7 @@ public final class SawtuskDemolisher extends CardImpl {
|
||||||
// Whenever this creature mutates, destroy target noncreature permanent. Its controller creates a 3/3 green Beast creature token.
|
// Whenever this creature mutates, destroy target noncreature permanent. Its controller creates a 3/3 green Beast creature token.
|
||||||
Ability ability = new MutatesSourceTriggeredAbility(new DestroyTargetEffect());
|
Ability ability = new MutatesSourceTriggeredAbility(new DestroyTargetEffect());
|
||||||
ability.addEffect(new CreateTokenControllerTargetEffect(new BeastToken()));
|
ability.addEffect(new CreateTokenControllerTargetEffect(new BeastToken()));
|
||||||
ability.addTarget(new TargetPermanent(filter));
|
ability.addTarget(new TargetPermanent(StaticFilters.FILTER_PERMANENT_NON_CREATURE));
|
||||||
this.addAbility(ability);
|
this.addAbility(ability);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -66,36 +51,3 @@ public final class SawtuskDemolisher extends CardImpl {
|
||||||
return new SawtuskDemolisher(this);
|
return new SawtuskDemolisher(this);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class SawtuskDemolisherEffect extends OneShotEffect {
|
|
||||||
|
|
||||||
SawtuskDemolisherEffect() {
|
|
||||||
super(Outcome.Benefit);
|
|
||||||
staticText = "destroy target noncreature permanent. Its controller creates a 3/3 green Beast creature token.";
|
|
||||||
}
|
|
||||||
|
|
||||||
private SawtuskDemolisherEffect(final SawtuskDemolisherEffect effect) {
|
|
||||||
super(effect);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public SawtuskDemolisherEffect copy() {
|
|
||||||
return new SawtuskDemolisherEffect(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean apply(Game game, Ability source) {
|
|
||||||
Permanent permanent = game.getPermanent(source.getFirstTarget());
|
|
||||||
if (permanent == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
Player player = game.getPlayer(permanent.getControllerId());
|
|
||||||
permanent.destroy(source, game, false);
|
|
||||||
if (player == null) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
Effect effect = new CreateTokenTargetEffect(new BeastToken());
|
|
||||||
effect.setTargetPointer(new FixedTarget(player.getId(), game));
|
|
||||||
return effect.apply(game, source);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
|
||||||
|
|
@ -12,9 +12,8 @@ import mage.cards.CardSetInfo;
|
||||||
import mage.constants.CardType;
|
import mage.constants.CardType;
|
||||||
import mage.constants.Outcome;
|
import mage.constants.Outcome;
|
||||||
import mage.constants.SubType;
|
import mage.constants.SubType;
|
||||||
import mage.filter.FilterPermanent;
|
import mage.filter.StaticFilters;
|
||||||
import mage.filter.common.FilterLandCard;
|
import mage.filter.common.FilterLandCard;
|
||||||
import mage.filter.predicate.Predicates;
|
|
||||||
import mage.game.Game;
|
import mage.game.Game;
|
||||||
import mage.game.permanent.Permanent;
|
import mage.game.permanent.Permanent;
|
||||||
import mage.target.Target;
|
import mage.target.Target;
|
||||||
|
|
@ -29,11 +28,6 @@ import java.util.UUID;
|
||||||
*/
|
*/
|
||||||
public final class SylvanPrimordial extends CardImpl {
|
public final class SylvanPrimordial extends CardImpl {
|
||||||
|
|
||||||
private static final FilterPermanent filter = new FilterPermanent("noncreature permanent");
|
|
||||||
|
|
||||||
static {
|
|
||||||
filter.add(Predicates.not(CardType.CREATURE.getPredicate()));
|
|
||||||
}
|
|
||||||
public SylvanPrimordial(UUID ownerId, CardSetInfo setInfo) {
|
public SylvanPrimordial(UUID ownerId, CardSetInfo setInfo) {
|
||||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{5}{G}{G}");
|
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{5}{G}{G}");
|
||||||
this.subtype.add(SubType.AVATAR);
|
this.subtype.add(SubType.AVATAR);
|
||||||
|
|
@ -46,7 +40,7 @@ public final class SylvanPrimordial extends CardImpl {
|
||||||
|
|
||||||
// When Sylvan Primordial enters the battlefield, for each opponent, destroy target noncreature permanent that player controls. For each permanent destroyed this way, search your library for a Forest card and put that card onto the battlefield tapped. Then shuffle your library.
|
// When Sylvan Primordial enters the battlefield, for each opponent, destroy target noncreature permanent that player controls. For each permanent destroyed this way, search your library for a Forest card and put that card onto the battlefield tapped. Then shuffle your library.
|
||||||
Ability ability = new EntersBattlefieldTriggeredAbility(new SylvanPrimordialEffect(), false);
|
Ability ability = new EntersBattlefieldTriggeredAbility(new SylvanPrimordialEffect(), false);
|
||||||
ability.addTarget(new TargetPermanent(filter));
|
ability.addTarget(new TargetPermanent(StaticFilters.FILTER_PERMANENT_NON_CREATURE));
|
||||||
ability.setTargetAdjuster(new ForEachPlayerTargetsAdjuster(false, true));
|
ability.setTargetAdjuster(new ForEachPlayerTargetsAdjuster(false, true));
|
||||||
this.addAbility(ability);
|
this.addAbility(ability);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,3 @@
|
||||||
|
|
||||||
package mage.cards.t;
|
package mage.cards.t;
|
||||||
|
|
||||||
import mage.MageInt;
|
import mage.MageInt;
|
||||||
|
|
@ -8,11 +7,10 @@ import mage.abilities.effects.OneShotEffect;
|
||||||
import mage.cards.CardImpl;
|
import mage.cards.CardImpl;
|
||||||
import mage.cards.CardSetInfo;
|
import mage.cards.CardSetInfo;
|
||||||
import mage.constants.CardType;
|
import mage.constants.CardType;
|
||||||
import mage.constants.SubType;
|
|
||||||
import mage.constants.Outcome;
|
import mage.constants.Outcome;
|
||||||
|
import mage.constants.SubType;
|
||||||
import mage.constants.Zone;
|
import mage.constants.Zone;
|
||||||
import mage.filter.FilterPermanent;
|
import mage.filter.StaticFilters;
|
||||||
import mage.filter.predicate.Predicates;
|
|
||||||
import mage.game.Game;
|
import mage.game.Game;
|
||||||
import mage.game.permanent.Permanent;
|
import mage.game.permanent.Permanent;
|
||||||
import mage.game.permanent.token.ElephantToken;
|
import mage.game.permanent.token.ElephantToken;
|
||||||
|
|
@ -24,17 +22,10 @@ import java.util.Map.Entry;
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
|
||||||
* @author jeffwadsworth
|
* @author jeffwadsworth
|
||||||
*/
|
*/
|
||||||
public final class Terastodon extends CardImpl {
|
public final class Terastodon extends CardImpl {
|
||||||
|
|
||||||
private static final FilterPermanent filter = new FilterPermanent("noncreature permanent");
|
|
||||||
|
|
||||||
static {
|
|
||||||
filter.add(Predicates.not(CardType.CREATURE.getPredicate()));
|
|
||||||
}
|
|
||||||
|
|
||||||
public Terastodon(UUID ownerId, CardSetInfo setInfo) {
|
public Terastodon(UUID ownerId, CardSetInfo setInfo) {
|
||||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{6}{G}{G}");
|
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{6}{G}{G}");
|
||||||
this.subtype.add(SubType.ELEPHANT);
|
this.subtype.add(SubType.ELEPHANT);
|
||||||
|
|
@ -44,7 +35,7 @@ public final class Terastodon extends CardImpl {
|
||||||
|
|
||||||
// When Terastodon enters the battlefield, you may destroy up to three target noncreature permanents. For each permanent put into a graveyard this way, its controller creates a 3/3 green Elephant creature token.
|
// When Terastodon enters the battlefield, you may destroy up to three target noncreature permanents. For each permanent put into a graveyard this way, its controller creates a 3/3 green Elephant creature token.
|
||||||
Ability ability = new EntersBattlefieldTriggeredAbility(new TerastodonEffect(), true);
|
Ability ability = new EntersBattlefieldTriggeredAbility(new TerastodonEffect(), true);
|
||||||
ability.addTarget(new TargetPermanent(0, 3, filter, false));
|
ability.addTarget(new TargetPermanent(0, 3, StaticFilters.FILTER_PERMANENT_NON_CREATURE, false));
|
||||||
this.addAbility(ability);
|
this.addAbility(ability);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,5 @@
|
||||||
|
|
||||||
package mage.cards.w;
|
package mage.cards.w;
|
||||||
|
|
||||||
import java.util.UUID;
|
|
||||||
import mage.MageInt;
|
import mage.MageInt;
|
||||||
import mage.abilities.Ability;
|
import mage.abilities.Ability;
|
||||||
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
|
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
|
||||||
|
|
@ -12,23 +10,18 @@ import mage.cards.CardImpl;
|
||||||
import mage.cards.CardSetInfo;
|
import mage.cards.CardSetInfo;
|
||||||
import mage.constants.CardType;
|
import mage.constants.CardType;
|
||||||
import mage.constants.SubType;
|
import mage.constants.SubType;
|
||||||
import mage.filter.FilterPermanent;
|
import mage.filter.StaticFilters;
|
||||||
import mage.filter.predicate.Predicates;
|
|
||||||
import mage.target.TargetPermanent;
|
import mage.target.TargetPermanent;
|
||||||
|
|
||||||
|
import java.util.UUID;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
|
||||||
* @author LevelX2
|
* @author LevelX2
|
||||||
*/
|
*/
|
||||||
public final class WoodfallPrimus extends CardImpl {
|
public final class WoodfallPrimus extends CardImpl {
|
||||||
|
|
||||||
private static final FilterPermanent filter = new FilterPermanent("noncreature permanent");
|
|
||||||
static {
|
|
||||||
filter.add(Predicates.not(CardType.CREATURE.getPredicate()));
|
|
||||||
}
|
|
||||||
|
|
||||||
public WoodfallPrimus(UUID ownerId, CardSetInfo setInfo) {
|
public WoodfallPrimus(UUID ownerId, CardSetInfo setInfo) {
|
||||||
super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{5}{G}{G}{G}");
|
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{5}{G}{G}{G}");
|
||||||
this.subtype.add(SubType.TREEFOLK);
|
this.subtype.add(SubType.TREEFOLK);
|
||||||
this.subtype.add(SubType.SHAMAN);
|
this.subtype.add(SubType.SHAMAN);
|
||||||
|
|
||||||
|
|
@ -37,10 +30,12 @@ public final class WoodfallPrimus extends CardImpl {
|
||||||
|
|
||||||
// Trample
|
// Trample
|
||||||
this.addAbility(TrampleAbility.getInstance());
|
this.addAbility(TrampleAbility.getInstance());
|
||||||
|
|
||||||
// When Woodfall Primus enters the battlefield, destroy target noncreature permanent.
|
// When Woodfall Primus enters the battlefield, destroy target noncreature permanent.
|
||||||
Ability ability = new EntersBattlefieldTriggeredAbility(new DestroyTargetEffect(), false);
|
Ability ability = new EntersBattlefieldTriggeredAbility(new DestroyTargetEffect());
|
||||||
ability.addTarget(new TargetPermanent(filter));
|
ability.addTarget(new TargetPermanent(StaticFilters.FILTER_PERMANENT_NON_CREATURE));
|
||||||
this.addAbility(ability);
|
this.addAbility(ability);
|
||||||
|
|
||||||
// Persist
|
// Persist
|
||||||
this.addAbility(new PersistAbility());
|
this.addAbility(new PersistAbility());
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -55,6 +55,8 @@ public final class EdgeOfEternities extends ExpansionSet {
|
||||||
cards.add(new SetCardInfo("Exalted Sunborn", 318, Rarity.MYTHIC, mage.cards.e.ExaltedSunborn.class, NON_FULL_USE_VARIOUS));
|
cards.add(new SetCardInfo("Exalted Sunborn", 318, Rarity.MYTHIC, mage.cards.e.ExaltedSunborn.class, NON_FULL_USE_VARIOUS));
|
||||||
cards.add(new SetCardInfo("Exalted Sunborn", 358, Rarity.MYTHIC, mage.cards.e.ExaltedSunborn.class, NON_FULL_USE_VARIOUS));
|
cards.add(new SetCardInfo("Exalted Sunborn", 358, Rarity.MYTHIC, mage.cards.e.ExaltedSunborn.class, NON_FULL_USE_VARIOUS));
|
||||||
cards.add(new SetCardInfo("Exalted Sunborn", 384, Rarity.MYTHIC, mage.cards.e.ExaltedSunborn.class, NON_FULL_USE_VARIOUS));
|
cards.add(new SetCardInfo("Exalted Sunborn", 384, Rarity.MYTHIC, mage.cards.e.ExaltedSunborn.class, NON_FULL_USE_VARIOUS));
|
||||||
|
cards.add(new SetCardInfo("Extinguisher Battleship", 242, Rarity.RARE, mage.cards.e.ExtinguisherBattleship.class, NON_FULL_USE_VARIOUS));
|
||||||
|
cards.add(new SetCardInfo("Extinguisher Battleship", 355, Rarity.RARE, mage.cards.e.ExtinguisherBattleship.class, NON_FULL_USE_VARIOUS));
|
||||||
cards.add(new SetCardInfo("Forest", 266, Rarity.LAND, mage.cards.basiclands.Forest.class, FULL_ART_BFZ_VARIOUS));
|
cards.add(new SetCardInfo("Forest", 266, Rarity.LAND, mage.cards.basiclands.Forest.class, FULL_ART_BFZ_VARIOUS));
|
||||||
cards.add(new SetCardInfo("Forest", 275, Rarity.LAND, mage.cards.basiclands.Forest.class, NON_FULL_USE_VARIOUS));
|
cards.add(new SetCardInfo("Forest", 275, Rarity.LAND, mage.cards.basiclands.Forest.class, NON_FULL_USE_VARIOUS));
|
||||||
cards.add(new SetCardInfo("Forest", 276, Rarity.LAND, mage.cards.basiclands.Forest.class, NON_FULL_USE_VARIOUS));
|
cards.add(new SetCardInfo("Forest", 276, Rarity.LAND, mage.cards.basiclands.Forest.class, NON_FULL_USE_VARIOUS));
|
||||||
|
|
|
||||||
|
|
@ -909,6 +909,13 @@ public final class StaticFilters {
|
||||||
FILTER_PERMANENT_BATTLES.setLockedFilter(true);
|
FILTER_PERMANENT_BATTLES.setLockedFilter(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static final FilterPermanent FILTER_PERMANENT_NON_CREATURE = new FilterPermanent("noncreature permanent");
|
||||||
|
|
||||||
|
static {
|
||||||
|
FILTER_PERMANENT_NON_CREATURE.add(Predicates.not(CardType.CREATURE.getPredicate()));
|
||||||
|
FILTER_PERMANENT_NON_CREATURE.setLockedFilter(true);
|
||||||
|
}
|
||||||
|
|
||||||
public static final FilterNonlandPermanent FILTER_PERMANENT_NON_LAND = new FilterNonlandPermanent();
|
public static final FilterNonlandPermanent FILTER_PERMANENT_NON_LAND = new FilterNonlandPermanent();
|
||||||
|
|
||||||
static {
|
static {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue