mirror of
https://github.com/correl/mage.git
synced 2024-12-25 03:00:15 +00:00
Add choose hints to abilities with sacrifice costs where the target and the permanent to sacrifice might be ambiguous (A-D)
This commit is contained in:
parent
9c0dfd1bbe
commit
12a20d07f4
17 changed files with 61 additions and 155 deletions
|
@ -30,12 +30,11 @@ public final class AidTheFallen extends CardImpl {
|
|||
this.getSpellAbility().addEffect(new ReturnFromGraveyardToHandTargetEffect());
|
||||
this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(
|
||||
StaticFilters.FILTER_CARD_CREATURE_YOUR_GRAVEYARD
|
||||
).withChooseHint("returns a creature card to your hand"));
|
||||
));
|
||||
|
||||
// • Return target planeswalker card from your graveyard to your hand.
|
||||
Mode mode = new Mode(new ReturnFromGraveyardToHandTargetEffect());
|
||||
mode.addTarget(new TargetCardInYourGraveyard(filter)
|
||||
.withChooseHint("returns a planeswalker card to your hand"));
|
||||
mode.addTarget(new TargetCardInYourGraveyard(filter));
|
||||
this.getSpellAbility().addMode(mode);
|
||||
}
|
||||
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.a;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -35,7 +34,7 @@ public final class AngelicPurge extends CardImpl {
|
|||
|
||||
// Exile target artifact, creature, or enchantment.
|
||||
this.getSpellAbility().addEffect(new ExileTargetEffect());
|
||||
this.getSpellAbility().addTarget(new TargetPermanent(filter));
|
||||
this.getSpellAbility().addTarget(new TargetPermanent(filter).withChooseHint("to exile"));
|
||||
}
|
||||
|
||||
private AngelicPurge(final AngelicPurge card) {
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.a;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -11,7 +10,6 @@ import mage.abilities.effects.common.DestroyTargetEffect;
|
|||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.FilterSpell;
|
||||
import mage.filter.common.FilterControlledPermanent;
|
||||
import mage.target.TargetSpell;
|
||||
|
@ -37,12 +35,12 @@ public final class ArensonsAura extends CardImpl {
|
|||
super(ownerId,setInfo,new CardType[]{CardType.ENCHANTMENT},"{2}{W}");
|
||||
|
||||
// {W}, Sacrifice an enchantment: Destroy target enchantment.
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DestroyTargetEffect(), new ManaCostsImpl<>("{W}"));
|
||||
Ability ability = new SimpleActivatedAbility(new DestroyTargetEffect(), new ManaCostsImpl<>("{W}"));
|
||||
ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(1, 1, filter, true)));
|
||||
ability.addTarget(new TargetEnchantmentPermanent());
|
||||
ability.addTarget(new TargetEnchantmentPermanent().withChooseHint("to destroy"));
|
||||
this.addAbility(ability);
|
||||
// {3}{U}{U}: Counter target enchantment spell.
|
||||
ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CounterTargetEffect(), new ManaCostsImpl<>("{3}{U}{U}"));
|
||||
ability = new SimpleActivatedAbility(new CounterTargetEffect(), new ManaCostsImpl<>("{3}{U}{U}"));
|
||||
ability.addTarget(new TargetSpell(filter2));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
|
|
@ -3,12 +3,12 @@ package mage.cards.a;
|
|||
import java.util.UUID;
|
||||
import mage.abilities.common.SimpleActivatedAbility;
|
||||
import mage.abilities.costs.common.SacrificeTargetCost;
|
||||
import mage.abilities.costs.mana.ManaCostsImpl;
|
||||
import mage.abilities.costs.mana.ColoredManaCost;
|
||||
import mage.abilities.effects.common.DestroyTargetEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Zone;
|
||||
import mage.constants.ColoredManaSymbol;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.target.common.TargetControlledCreaturePermanent;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
|
@ -23,9 +23,9 @@ public final class Attrition extends CardImpl {
|
|||
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{1}{B}{B}");
|
||||
|
||||
//{B}, Sacrifice a creature: Destroy target nonblack creature.
|
||||
SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DestroyTargetEffect(), new ManaCostsImpl<>("{B}"));
|
||||
SimpleActivatedAbility ability = new SimpleActivatedAbility(new DestroyTargetEffect(), new ColoredManaCost(ColoredManaSymbol.B));
|
||||
ability.addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent(StaticFilters.FILTER_CONTROLLED_CREATURE_SHORT_TEXT)));
|
||||
ability.addTarget(new TargetCreaturePermanent(StaticFilters.FILTER_PERMANENT_CREATURE_NON_BLACK));
|
||||
ability.addTarget(new TargetCreaturePermanent(StaticFilters.FILTER_PERMANENT_CREATURE_NON_BLACK).withChooseHint("to destroy"));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.a;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -36,8 +35,7 @@ public final class AyliEternalPilgrim extends CardImpl {
|
|||
public AyliEternalPilgrim(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{W}{B}");
|
||||
this.addSuperType(SuperType.LEGENDARY);
|
||||
this.subtype.add(SubType.KOR);
|
||||
this.subtype.add(SubType.CLERIC);
|
||||
this.subtype.add(SubType.KOR, SubType.CLERIC);
|
||||
this.power = new MageInt(2);
|
||||
this.toughness = new MageInt(3);
|
||||
|
||||
|
@ -51,15 +49,15 @@ public final class AyliEternalPilgrim extends CardImpl {
|
|||
ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(StaticFilters.FILTER_CONTROLLED_ANOTHER_CREATURE)));
|
||||
this.addAbility(ability);
|
||||
|
||||
// {1}{W}{B}, Sacrifice another creature: Exile target nonland permanent. Activate this ability only if you have at least 10 life more than your starting life total.
|
||||
// {1}{W}{B}, Sacrifice another creature: Exile target nonland permanent. Activate only if you have at least 10 life more than your starting life total.
|
||||
ability = new ConditionalActivatedAbility(
|
||||
Zone.BATTLEFIELD,
|
||||
new ExileTargetEffect(),
|
||||
new ManaCostsImpl<>("{1}{W}{B}"),
|
||||
new AyliEternalPilgrimCondition(),
|
||||
"{1}{W}{B}, Sacrifice another creature: Exile target nonland permanent. Activate only if you have at least 10 life more than your starting life total.");
|
||||
new AyliEternalPilgrimCondition()
|
||||
);
|
||||
ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(StaticFilters.FILTER_CONTROLLED_ANOTHER_CREATURE)));
|
||||
ability.addTarget(new TargetNonlandPermanent());
|
||||
ability.addTarget(new TargetNonlandPermanent().withChooseHint("to exile"));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
||||
|
@ -83,4 +81,9 @@ class AyliEternalPilgrimCondition implements Condition {
|
|||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "you have at least 10 life more than your starting life total";
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.b;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -24,8 +23,8 @@ public final class BoneSplinters extends CardImpl {
|
|||
// As an additional cost to cast Bone Splinters, sacrifice a creature.
|
||||
this.getSpellAbility().addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent(FILTER_CONTROLLED_CREATURE_SHORT_TEXT)));
|
||||
// Destroy target creature.
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanent(new FilterCreaturePermanent("creature (to destoy)")));
|
||||
this.getSpellAbility().addEffect(new DestroyTargetEffect("Destroy target creature"));
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanent().withChooseHint("to destroy"));
|
||||
this.getSpellAbility().addEffect(new DestroyTargetEffect());
|
||||
}
|
||||
|
||||
private BoneSplinters(final BoneSplinters card) {
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.c;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -13,9 +12,7 @@ import mage.cards.CardImpl;
|
|||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SubType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.SuperType;
|
||||
import mage.constants.Zone;
|
||||
import static mage.filter.StaticFilters.FILTER_CONTROLLED_CREATURE_SHORT_TEXT;
|
||||
import mage.filter.common.FilterCreatureCard;
|
||||
import mage.target.common.TargetCardInYourGraveyard;
|
||||
|
@ -31,23 +28,21 @@ public final class CabalPatriarch extends CardImpl {
|
|||
public CabalPatriarch(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{3}{B}{B}{B}");
|
||||
addSuperType(SuperType.LEGENDARY);
|
||||
this.subtype.add(SubType.HUMAN);
|
||||
this.subtype.add(SubType.WIZARD);
|
||||
this.subtype.add(SubType.HUMAN, SubType.WIZARD);
|
||||
|
||||
this.power = new MageInt(5);
|
||||
this.toughness = new MageInt(5);
|
||||
|
||||
// {2}{B}, Sacrifice a creature: Target creature gets -2/-2 until end of turn.
|
||||
Ability ability1 = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(-2, -2, Duration.EndOfTurn), new ManaCostsImpl<>("{2}{B}"));
|
||||
TargetControlledPermanent target = new TargetControlledPermanent(FILTER_CONTROLLED_CREATURE_SHORT_TEXT);
|
||||
ability1.addCost(new SacrificeTargetCost(target));
|
||||
ability1.addTarget(new TargetCreaturePermanent());
|
||||
Ability ability1 = new SimpleActivatedAbility(new BoostTargetEffect(-2, -2), new ManaCostsImpl<>("{2}{B}"));
|
||||
ability1.addCost(new SacrificeTargetCost(new TargetControlledPermanent(FILTER_CONTROLLED_CREATURE_SHORT_TEXT)));
|
||||
ability1.addTarget(new TargetCreaturePermanent().withChooseHint("gets -2/-2"));
|
||||
this.addAbility(ability1);
|
||||
|
||||
// {2}{B}, Exile a creature card from your graveyard: Target creature gets -2/-2 until end of turn.
|
||||
Ability ability2 = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(-2, -2, Duration.EndOfTurn), new ManaCostsImpl<>("{2}{B}"));
|
||||
Ability ability2 = new SimpleActivatedAbility(new BoostTargetEffect(-2, -2), new ManaCostsImpl<>("{2}{B}"));
|
||||
ability2.addCost(new ExileFromGraveCost(new TargetCardInYourGraveyard(new FilterCreatureCard("a creature card"))));
|
||||
ability2.addTarget(new TargetCreaturePermanent());
|
||||
ability2.addTarget(new TargetCreaturePermanent().withChooseHint("gets -2/-2"));
|
||||
this.addAbility(ability2);
|
||||
}
|
||||
|
||||
|
|
|
@ -12,9 +12,7 @@ import mage.cards.CardSetInfo;
|
|||
import mage.constants.CardType;
|
||||
import mage.constants.SubType;
|
||||
import mage.constants.SuperType;
|
||||
import mage.filter.FilterPermanent;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.filter.predicate.Predicates;
|
||||
import mage.game.permanent.token.DarettiConstructToken;
|
||||
import mage.target.TargetPermanent;
|
||||
import mage.target.common.TargetCardInGraveyardBattlefieldOrStack;
|
||||
|
@ -27,16 +25,6 @@ import java.util.UUID;
|
|||
*/
|
||||
public final class DarettiIngeniousIconoclast extends CardImpl {
|
||||
|
||||
private static final FilterPermanent filter
|
||||
= new FilterPermanent("artifact or creature (to destroy)");
|
||||
|
||||
static {
|
||||
filter.add(Predicates.or(
|
||||
CardType.ARTIFACT.getPredicate(),
|
||||
CardType.CREATURE.getPredicate()
|
||||
));
|
||||
}
|
||||
|
||||
public DarettiIngeniousIconoclast(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.PLANESWALKER}, "{1}{B}{R}");
|
||||
this.addSuperType(SuperType.LEGENDARY);
|
||||
|
@ -50,13 +38,13 @@ public final class DarettiIngeniousIconoclast extends CardImpl {
|
|||
// -1: You may sacrifice an artifact. If you do, destroy target artifact or creature.
|
||||
Ability ability = new LoyaltyAbility(
|
||||
new DoIfCostPaid(
|
||||
new DestroyTargetEffect("destroy target artifact or creature"),
|
||||
new DestroyTargetEffect(),
|
||||
new SacrificeTargetCost(new TargetControlledPermanent(
|
||||
StaticFilters.FILTER_CONTROLLED_PERMANENT_ARTIFACT_AN
|
||||
))
|
||||
), -1
|
||||
);
|
||||
ability.addTarget(new TargetPermanent(filter));
|
||||
ability.addTarget(new TargetPermanent(StaticFilters.FILTER_PERMANENT_ARTIFACT_OR_CREATURE).withChooseHint("to destroy"));
|
||||
this.addAbility(ability);
|
||||
|
||||
// -6: Choose target artifact card in a graveyard or artifact on the battlefield. Create three tokens that are copies of it.
|
||||
|
|
|
@ -25,7 +25,7 @@ public final class DeathBomb extends CardImpl {
|
|||
// Destroy target nonblack creature. It can't be regenerated. Its controller loses 2 life.
|
||||
this.getSpellAbility().addEffect(new DestroyTargetEffect(true));
|
||||
this.getSpellAbility().addEffect(new LoseLifeTargetControllerEffect(2));
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanent(StaticFilters.FILTER_PERMANENT_CREATURE_NON_BLACK));
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanent(StaticFilters.FILTER_PERMANENT_CREATURE_NON_BLACK).withChooseHint("to destroy"));
|
||||
}
|
||||
|
||||
private DeathBomb(final DeathBomb card) {
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.d;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -12,7 +11,6 @@ import mage.cards.CardImpl;
|
|||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SubType;
|
||||
import mage.constants.Zone;
|
||||
import mage.counters.CounterType;
|
||||
import mage.filter.common.FilterControlledPermanent;
|
||||
import mage.target.common.TargetControlledPermanent;
|
||||
|
@ -31,16 +29,15 @@ public final class DerangedOutcast extends CardImpl {
|
|||
|
||||
public DerangedOutcast(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{1}{G}");
|
||||
this.subtype.add(SubType.HUMAN);
|
||||
this.subtype.add(SubType.ROGUE);
|
||||
this.subtype.add(SubType.HUMAN, SubType.ROGUE);
|
||||
|
||||
this.power = new MageInt(2);
|
||||
this.toughness = new MageInt(1);
|
||||
|
||||
// {1}{G}, Sacrifice a Human: Put two +1/+1 counters on target creature.
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new AddCountersTargetEffect(CounterType.P1P1.createInstance(2)), new ManaCostsImpl<>("{1}{G}"));
|
||||
Ability ability = new SimpleActivatedAbility(new AddCountersTargetEffect(CounterType.P1P1.createInstance(2)), new ManaCostsImpl<>("{1}{G}"));
|
||||
ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(filter)));
|
||||
ability.addTarget(new TargetCreaturePermanent());
|
||||
ability.addTarget(new TargetCreaturePermanent().withChooseHint("two +1/+1 counters"));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.d;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -10,7 +9,6 @@ import mage.abilities.effects.common.ReturnToHandTargetEffect;
|
|||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Zone;
|
||||
import mage.target.TargetPermanent;
|
||||
import mage.target.common.TargetControlledPermanent;
|
||||
|
||||
|
@ -24,9 +22,9 @@ public final class DispersingOrb extends CardImpl {
|
|||
super(ownerId,setInfo,new CardType[]{CardType.ENCHANTMENT},"{3}{U}{U}");
|
||||
|
||||
// {3}{U}, Sacrifice a permanent: Return target permanent to its owner's hand.
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnToHandTargetEffect(), new ManaCostsImpl<>("{3}{U}"));
|
||||
Ability ability = new SimpleActivatedAbility(new ReturnToHandTargetEffect(), new ManaCostsImpl<>("{3}{U}"));
|
||||
ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent()));
|
||||
ability.addTarget(new TargetPermanent());
|
||||
ability.addTarget(new TargetPermanent().withChooseHint("return to hand"));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.d;
|
||||
|
||||
import mage.MageInt;
|
||||
|
@ -6,18 +5,17 @@ import mage.abilities.Ability;
|
|||
import mage.abilities.common.SimpleActivatedAbility;
|
||||
import mage.abilities.common.SimpleStaticAbility;
|
||||
import mage.abilities.costs.common.SacrificeTargetCost;
|
||||
import mage.abilities.costs.mana.ManaCostsImpl;
|
||||
import mage.abilities.costs.mana.ColoredManaCost;
|
||||
import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent;
|
||||
import mage.abilities.effects.common.continuous.BecomesBasicLandTargetEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.ColoredManaSymbol;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.SubType;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.common.FilterControlledLandPermanent;
|
||||
import mage.filter.common.FilterLandPermanent;
|
||||
import mage.target.Target;
|
||||
import mage.target.common.TargetControlledPermanent;
|
||||
import mage.target.common.TargetLandPermanent;
|
||||
|
||||
|
@ -37,11 +35,10 @@ public final class Dreamwinder extends CardImpl {
|
|||
this.toughness = new MageInt(3);
|
||||
|
||||
// Dreamwinder can't attack unless defending player controls an Island.
|
||||
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent(SubType.ISLAND,"an Island"))));
|
||||
this.addAbility(new SimpleStaticAbility(new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent(SubType.ISLAND,"an Island"))));
|
||||
// {U}, Sacrifice an Island: Target land becomes an Island until end of turn.
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesBasicLandTargetEffect(Duration.EndOfTurn, SubType.ISLAND), new ManaCostsImpl<>("{U}"));
|
||||
Target target = new TargetLandPermanent();
|
||||
ability.addTarget(target);
|
||||
Ability ability = new SimpleActivatedAbility(new BecomesBasicLandTargetEffect(Duration.EndOfTurn, SubType.ISLAND), new ColoredManaCost(ColoredManaSymbol.U));
|
||||
ability.addTarget(new TargetLandPermanent().withChooseHint("becomes an Island"));
|
||||
FilterControlledLandPermanent filter = new FilterControlledLandPermanent("an Island");
|
||||
filter.add(SubType.ISLAND.getPredicate());
|
||||
ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(1, 1, filter, true)));
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.d;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -7,17 +6,15 @@ import mage.abilities.Ability;
|
|||
import mage.abilities.common.SimpleActivatedAbility;
|
||||
import mage.abilities.costs.common.SacrificeTargetCost;
|
||||
import mage.abilities.costs.mana.ManaCostsImpl;
|
||||
import mage.abilities.effects.ContinuousEffectImpl;
|
||||
import mage.abilities.effects.common.continuous.BoostTargetEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.*;
|
||||
import static mage.filter.StaticFilters.FILTER_CONTROLLED_CREATURE_SHORT_TEXT;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
import mage.filter.predicate.other.AnotherTargetPredicate;
|
||||
import mage.game.Game;
|
||||
import mage.game.permanent.Permanent;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SubType;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.target.common.TargetControlledCreaturePermanent;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
import mage.target.targetpointer.SecondTargetPointer;
|
||||
|
||||
/**
|
||||
*
|
||||
|
@ -33,17 +30,18 @@ public final class DroolingGroodion extends CardImpl {
|
|||
this.toughness = new MageInt(3);
|
||||
|
||||
// {2}{B}{G}, Sacrifice a creature: Target creature gets +2/+2 until end of turn. Another target creature gets -2/-2 until end of turn.
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DroolingGroodionEffect(), new ManaCostsImpl<>("{2}{B}{G}"));
|
||||
ability.addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent(FILTER_CONTROLLED_CREATURE_SHORT_TEXT)));
|
||||
Ability ability = new SimpleActivatedAbility(new BoostTargetEffect(2, 2), new ManaCostsImpl<>("{2}{B}{G}"));
|
||||
ability.addEffect(new BoostTargetEffect(-2, -2).setTargetPointer(new SecondTargetPointer()));
|
||||
ability.addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent(StaticFilters.FILTER_CONTROLLED_CREATURE_SHORT_TEXT)));
|
||||
|
||||
TargetCreaturePermanent target = new TargetCreaturePermanent(new FilterCreaturePermanent("creature (first target)"));
|
||||
TargetCreaturePermanent target = new TargetCreaturePermanent();
|
||||
target.setTargetTag(1);
|
||||
target.withChooseHint("gets +2/+2");
|
||||
ability.addTarget(target);
|
||||
|
||||
FilterCreaturePermanent filter = new FilterCreaturePermanent("another target creature (second target");
|
||||
filter.add(new AnotherTargetPredicate(2));
|
||||
target = new TargetCreaturePermanent(filter);
|
||||
target = new TargetCreaturePermanent(StaticFilters.FILTER_ANOTHER_CREATURE_TARGET_2);
|
||||
target.setTargetTag(2);
|
||||
target.withChooseHint("gets -2/-2");
|
||||
ability.addTarget(target);
|
||||
|
||||
this.addAbility(ability);
|
||||
|
@ -58,35 +56,3 @@ public final class DroolingGroodion extends CardImpl {
|
|||
return new DroolingGroodion(this);
|
||||
}
|
||||
}
|
||||
|
||||
class DroolingGroodionEffect extends ContinuousEffectImpl {
|
||||
|
||||
public DroolingGroodionEffect() {
|
||||
super(Duration.EndOfTurn, Layer.PTChangingEffects_7, SubLayer.ModifyPT_7c, Outcome.BoostCreature);
|
||||
this.staticText = "Target creature gets +2/+2 until end of turn. Another target creature gets -2/-2 until end of turn";
|
||||
}
|
||||
|
||||
public DroolingGroodionEffect(final DroolingGroodionEffect effect) {
|
||||
super(effect);
|
||||
}
|
||||
|
||||
@Override
|
||||
public DroolingGroodionEffect copy() {
|
||||
return new DroolingGroodionEffect(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
Permanent permanent = game.getPermanent(source.getFirstTarget());
|
||||
if (permanent != null) {
|
||||
permanent.addPower(2);
|
||||
permanent.addToughness(2);
|
||||
}
|
||||
permanent = game.getPermanent(source.getTargets().get(1).getFirstTarget());
|
||||
if (permanent != null) {
|
||||
permanent.addPower(-2);
|
||||
permanent.addToughness(-2);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.d;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -12,9 +11,7 @@ import mage.abilities.mana.ColorlessManaAbility;
|
|||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.common.FilterControlledLandPermanent;
|
||||
import mage.target.Target;
|
||||
import mage.target.common.TargetControlledPermanent;
|
||||
import mage.target.common.TargetNonBasicLandPermanent;
|
||||
|
||||
|
@ -30,11 +27,10 @@ public final class DustBowl extends CardImpl {
|
|||
// {tap}: Add {C}.
|
||||
this.addAbility(new ColorlessManaAbility());
|
||||
// {3}, {tap}, Sacrifice a land: Destroy target nonbasic land.
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DestroyTargetEffect(), new GenericManaCost(3));
|
||||
Ability ability = new SimpleActivatedAbility(new DestroyTargetEffect(), new GenericManaCost(3));
|
||||
ability.addCost(new TapSourceCost());
|
||||
ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent("a land"))));
|
||||
Target target = new TargetNonBasicLandPermanent();
|
||||
ability.addTarget(target);
|
||||
ability.addTarget(new TargetNonBasicLandPermanent().withChooseHint("to destroy"));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
||||
|
|
|
@ -26,7 +26,7 @@ import java.util.UUID;
|
|||
*/
|
||||
public final class TeysaOrzhovScion extends CardImpl {
|
||||
|
||||
private static final FilterControlledCreaturePermanent filterWhite = new FilterControlledCreaturePermanent("three white creatures");
|
||||
private static final FilterControlledCreaturePermanent filterWhite = new FilterControlledCreaturePermanent("white creatures");
|
||||
private static final FilterCreaturePermanent filterBlack = new FilterCreaturePermanent("another black creature you control");
|
||||
|
||||
static {
|
||||
|
@ -46,8 +46,8 @@ public final class TeysaOrzhovScion extends CardImpl {
|
|||
this.toughness = new MageInt(3);
|
||||
|
||||
// Sacrifice three white creatures: Exile target creature.
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ExileTargetEffect(), new SacrificeTargetCost(new TargetControlledCreaturePermanent(3, 3, filterWhite, true)));
|
||||
ability.addTarget(new TargetCreaturePermanent());
|
||||
Ability ability = new SimpleActivatedAbility(new ExileTargetEffect(), new SacrificeTargetCost(new TargetControlledCreaturePermanent(3, 3, filterWhite, true)));
|
||||
ability.addTarget(new TargetCreaturePermanent().withChooseHint("to exile"));
|
||||
this.addAbility(ability);
|
||||
|
||||
// Whenever another black creature you control dies, create a 1/1 white Spirit creature token with flying.
|
||||
|
|
|
@ -11,10 +11,8 @@ import mage.constants.Outcome;
|
|||
import mage.constants.SubLayer;
|
||||
import mage.game.Game;
|
||||
import mage.game.permanent.Permanent;
|
||||
import mage.target.Target;
|
||||
import mage.util.CardUtil;
|
||||
|
||||
import java.util.Locale;
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
|
@ -83,27 +81,8 @@ public class BoostTargetEffect extends ContinuousEffectImpl {
|
|||
if (staticText != null && !staticText.isEmpty()) {
|
||||
return staticText;
|
||||
}
|
||||
StringBuilder sb = new StringBuilder();
|
||||
if (mode == null || mode.getTargets().isEmpty()) {
|
||||
sb.append("it gets ");
|
||||
} else {
|
||||
Target target = mode.getTargets().get(0);
|
||||
if (target.getMaxNumberOfTargets() > 1) {
|
||||
if (target.getNumberOfTargets() < target.getMaxNumberOfTargets()) {
|
||||
sb.append("up to ");
|
||||
}
|
||||
sb.append(CardUtil.numberToText(target.getMaxNumberOfTargets())).append(" target ").append(target.getTargetName()).append(" get ");
|
||||
} else {
|
||||
if (target.getNumberOfTargets() < target.getMaxNumberOfTargets()) {
|
||||
sb.append("up to ").append(CardUtil.numberToText(target.getMaxNumberOfTargets())).append(' ');
|
||||
}
|
||||
if (!target.getTargetName().toLowerCase(Locale.ENGLISH).startsWith("another")) {
|
||||
sb.append("target ");
|
||||
}
|
||||
sb.append(target.getTargetName()).append(" gets ");
|
||||
}
|
||||
}
|
||||
sb.append(CardUtil.getBoostText(power, toughness, duration));
|
||||
return sb.toString();
|
||||
return getTargetPointer().describeTargets(mode.getTargets(), "it") +
|
||||
(getTargetPointer().isPlural(mode.getTargets()) ? " get " : " gets ") +
|
||||
CardUtil.getBoostText(power, toughness, duration);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -141,14 +141,6 @@ public final class RateCard {
|
|||
// found removal
|
||||
return 1;
|
||||
}
|
||||
//static List<Effect> removalEffects =[BoostTargetEffect,BoostEnchantedEffect]
|
||||
if (effect instanceof BoostTargetEffect || effect instanceof BoostEnchantedEffect) {
|
||||
String text = effect.getText(null);
|
||||
if (text.contains("/-")) {
|
||||
// toughness reducer, aka removal
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
if (effect instanceof FightTargetsEffect
|
||||
|| effect instanceof DamageWithPowerFromOneToAnotherTargetEffect
|
||||
|| effect instanceof DamageWithPowerFromSourceToAnotherTargetEffect) {
|
||||
|
|
Loading…
Reference in a new issue