mirror of
https://github.com/correl/mage.git
synced 2024-12-24 11:50:45 +00:00
- Fixed #6838
This commit is contained in:
parent
bd9738f128
commit
bfb7a1a24d
14 changed files with 107 additions and 76 deletions
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.a;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -13,6 +12,7 @@ import mage.cards.CardImpl;
|
|||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SubType;
|
||||
import mage.constants.Zone;
|
||||
import mage.counters.CounterType;
|
||||
|
@ -26,13 +26,15 @@ import mage.target.common.TargetCreaturePermanent;
|
|||
*/
|
||||
public final class AquastrandSpider extends CardImpl {
|
||||
|
||||
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature with a +1/+1 counter on it");
|
||||
static {
|
||||
filter.add(new CounterPredicate(CounterType.P1P1));
|
||||
}
|
||||
private static final FilterCreaturePermanent filter
|
||||
= new FilterCreaturePermanent("creature with a +1/+1 counter on it");
|
||||
|
||||
static {
|
||||
filter.add(new CounterPredicate(CounterType.P1P1));
|
||||
}
|
||||
|
||||
public AquastrandSpider(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{1}{G}");
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{1}{G}");
|
||||
this.subtype.add(SubType.SPIDER);
|
||||
this.subtype.add(SubType.MUTANT);
|
||||
this.power = new MageInt(0);
|
||||
|
@ -40,17 +42,19 @@ public final class AquastrandSpider extends CardImpl {
|
|||
|
||||
// Graft 2
|
||||
this.addAbility(new GraftAbility(this, 2));
|
||||
|
||||
// {G}: Target creature with a +1/+1 counter on it gains reach until end of turn.
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilityTargetEffect(ReachAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl("{G}"));
|
||||
ability.addTarget(new TargetCreaturePermanent(filter));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
||||
// {G}: Target creature with a +1/+1 counter on it gains reach until end of turn.
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD,
|
||||
new GainAbilityTargetEffect(ReachAbility.getInstance(),
|
||||
Duration.EndOfTurn), new ManaCostsImpl("{G}"));
|
||||
ability.addTarget(new TargetCreaturePermanent(filter));
|
||||
this.addAbility(ability.addCustomOutcome(Outcome.Benefit));
|
||||
}
|
||||
|
||||
public AquastrandSpider(final AquastrandSpider card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public AquastrandSpider copy() {
|
||||
return new AquastrandSpider(this);
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.a;
|
||||
|
||||
import mage.abilities.Ability;
|
||||
|
@ -22,8 +21,12 @@ public final class AuraShards extends CardImpl {
|
|||
public AuraShards(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{1}{G}{W}");
|
||||
|
||||
// Whenever a creature enters the battlefield under your control, you may destroy target artifact or enchantment.
|
||||
Ability ability = new EntersBattlefieldControlledTriggeredAbility(Zone.BATTLEFIELD, new DestroyTargetEffect(), StaticFilters.FILTER_PERMANENT_CREATURE, true, "Whenever a creature enters the battlefield under your control, you may destroy target artifact or enchantment");
|
||||
// Whenever a creature enters the battlefield under your control,
|
||||
// you may destroy target artifact or enchantment.
|
||||
Ability ability = new EntersBattlefieldControlledTriggeredAbility(Zone.BATTLEFIELD,
|
||||
new DestroyTargetEffect(), StaticFilters.FILTER_PERMANENT_CREATURE, true,
|
||||
"Whenever a creature enters the battlefield under your control, "
|
||||
+ "you may destroy target artifact or enchantment");
|
||||
ability.addTarget(new TargetPermanent(StaticFilters.FILTER_PERMANENT_ARTIFACT_OR_ENCHANTMENT));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
|
|
@ -41,7 +41,7 @@ public final class BeastWithin extends CardImpl {
|
|||
class BeastWithinEffect extends OneShotEffect {
|
||||
|
||||
public BeastWithinEffect() {
|
||||
super(Outcome.PutCreatureInPlay);
|
||||
super(Outcome.Detriment);
|
||||
staticText = "Its controller creates a 3/3 green Beast creature token";
|
||||
}
|
||||
|
||||
|
|
|
@ -1,15 +1,16 @@
|
|||
|
||||
package mage.cards.d;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.TriggeredAbilityImpl;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.continuous.GainAbilityTargetEffect;
|
||||
import mage.abilities.keyword.DoubleStrikeAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.common.FilterAttackingCreature;
|
||||
import mage.game.Game;
|
||||
|
@ -22,21 +23,25 @@ import mage.target.common.TargetCreaturePermanent;
|
|||
* @author fireshoes
|
||||
*/
|
||||
public final class DuelistsHeritage extends CardImpl {
|
||||
|
||||
|
||||
public DuelistsHeritage(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{2}{W}");
|
||||
|
||||
|
||||
// Whenever one or more creatures attack, you may have target attacking creature gain double strike until end of turn.
|
||||
Ability ability = new DuelistsHeritageTriggeredAbility();
|
||||
// Whenever one or more creatures attack, you may have target attacking
|
||||
// creature gain double strike until end of turn.
|
||||
Effect effect = new GainAbilityTargetEffect(DoubleStrikeAbility.getInstance(),
|
||||
Duration.EndOfTurn);
|
||||
effect.setOutcome(Outcome.Benefit);
|
||||
Ability ability = new DuelistsHeritageTriggeredAbility(
|
||||
Zone.BATTLEFIELD, effect);
|
||||
ability.addTarget(new TargetCreaturePermanent(new FilterAttackingCreature()));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
||||
|
||||
public DuelistsHeritage(final DuelistsHeritage card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public DuelistsHeritage copy() {
|
||||
return new DuelistsHeritage(this);
|
||||
|
@ -44,30 +49,30 @@ public final class DuelistsHeritage extends CardImpl {
|
|||
}
|
||||
|
||||
class DuelistsHeritageTriggeredAbility extends TriggeredAbilityImpl {
|
||||
|
||||
public DuelistsHeritageTriggeredAbility() {
|
||||
super(Zone.BATTLEFIELD, new GainAbilityTargetEffect(DoubleStrikeAbility.getInstance(), Duration.EndOfTurn), true);
|
||||
|
||||
public DuelistsHeritageTriggeredAbility(Zone zone, Effect effect) {
|
||||
super(zone, effect, true);
|
||||
}
|
||||
|
||||
|
||||
public DuelistsHeritageTriggeredAbility(final DuelistsHeritageTriggeredAbility ability) {
|
||||
super(ability);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public DuelistsHeritageTriggeredAbility copy() {
|
||||
return new DuelistsHeritageTriggeredAbility(this);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public boolean checkEventType(GameEvent event, Game game) {
|
||||
return event.getType() == EventType.DECLARED_ATTACKERS;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public boolean checkTrigger(GameEvent event, Game game) {
|
||||
return !game.getCombat().getAttackers().isEmpty();
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public String getRule() {
|
||||
return "Whenever one or more creatures attack, " + super.getRule();
|
||||
|
|
|
@ -21,8 +21,8 @@ import mage.target.common.TargetCreaturePermanent;
|
|||
public final class InevitableEnd extends CardImpl {
|
||||
|
||||
public InevitableEnd(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[] {CardType.ENCHANTMENT},
|
||||
"{2}{B}");
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT},
|
||||
"{2}{B}");
|
||||
|
||||
this.subtype.add(SubType.AURA);
|
||||
|
||||
|
@ -30,23 +30,25 @@ public final class InevitableEnd extends CardImpl {
|
|||
TargetPermanent auraTarget = new TargetCreaturePermanent();
|
||||
this.getSpellAbility().addTarget(auraTarget);
|
||||
this.getSpellAbility().addEffect(
|
||||
new AttachEffect(Outcome.BoostCreature));
|
||||
new AttachEffect(Outcome.Detriment));
|
||||
Ability ability = new EnchantAbility(auraTarget.getTargetName());
|
||||
this.addAbility(ability);
|
||||
|
||||
// Enchanted creature has "At the beginning of your upkeep, sacrifice a
|
||||
// creature."
|
||||
BeginningOfUpkeepTriggeredAbility triggeredAbility =
|
||||
new BeginningOfUpkeepTriggeredAbility(
|
||||
new SacrificeControllerEffect(
|
||||
StaticFilters.FILTER_PERMANENT_CREATURE, 1, null),
|
||||
TargetController.YOU, false);
|
||||
BeginningOfUpkeepTriggeredAbility triggeredAbility
|
||||
= new BeginningOfUpkeepTriggeredAbility(
|
||||
new SacrificeControllerEffect(
|
||||
StaticFilters.FILTER_PERMANENT_CREATURE, 1, null),
|
||||
TargetController.YOU, false);
|
||||
this.addAbility(new SimpleStaticAbility(new GainAbilityAttachedEffect(
|
||||
triggeredAbility, AttachmentType.AURA, Duration.WhileOnBattlefield,
|
||||
"Enchanted creature has \"" + triggeredAbility.getRule() + "\"")));
|
||||
triggeredAbility, AttachmentType.AURA, Duration.WhileOnBattlefield,
|
||||
"Enchanted creature has \"" + triggeredAbility.getRule() + "\"")));
|
||||
}
|
||||
|
||||
private InevitableEnd(final InevitableEnd card) { super(card); }
|
||||
private InevitableEnd(final InevitableEnd card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public InevitableEnd copy() {
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.m;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -13,6 +12,7 @@ import mage.cards.CardImpl;
|
|||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.Zone;
|
||||
import mage.target.common.TargetAttackingCreature;
|
||||
|
||||
|
@ -21,26 +21,29 @@ import mage.target.common.TargetAttackingCreature;
|
|||
* @author Plopman
|
||||
*/
|
||||
public final class MazeOfIth extends CardImpl {
|
||||
|
||||
|
||||
public MazeOfIth(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.LAND},"");
|
||||
super(ownerId, setInfo, new CardType[]{CardType.LAND}, "");
|
||||
|
||||
// {tap}: Untap target attacking creature. Prevent all combat damage that would be dealt to and dealt by that creature this turn.
|
||||
// {T}: Untap target attacking creature. Prevent all combat damage that
|
||||
// would be dealt to and dealt by that creature this turn.
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new UntapTargetEffect(), new TapSourceCost());
|
||||
Effect effect = new PreventDamageByTargetEffect(Duration.EndOfTurn, true);
|
||||
effect.setText("Prevent all combat damage that would be dealt to");
|
||||
effect.setOutcome(Outcome.Detriment);
|
||||
ability.addEffect(effect);
|
||||
effect = new PreventDamageToTargetEffect(Duration.EndOfTurn, Integer.MAX_VALUE, true);
|
||||
effect.setText("and dealt by that creature this turn");
|
||||
effect.setOutcome(Outcome.Detriment);
|
||||
ability.addEffect(effect);
|
||||
ability.addTarget(new TargetAttackingCreature());
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
||||
|
||||
public MazeOfIth(final MazeOfIth card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public MazeOfIth copy() {
|
||||
return new MazeOfIth(this);
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.r;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -14,6 +13,7 @@ import mage.cards.CardImpl;
|
|||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.Outcome;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
|
||||
/**
|
||||
|
@ -23,19 +23,22 @@ import mage.target.common.TargetCreaturePermanent;
|
|||
public final class RetreatToHagra extends CardImpl {
|
||||
|
||||
public RetreatToHagra(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.ENCHANTMENT},"{2}{B}");
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{2}{B}");
|
||||
|
||||
// <i>Landfall</i>- Whenever a land enters the battlefield under your control, choose one - Target creature gets +1/+0 and gains deathtouch until end of turn;
|
||||
// <i>Landfall</i>- Whenever a land enters the battlefield under your control,
|
||||
// choose one - Target creature gets +1/+0 and gains deathtouch until end of turn;
|
||||
LandfallAbility ability = new LandfallAbility(new BoostTargetEffect(1, 0, Duration.EndOfTurn), false);
|
||||
ability.addEffect(new GainAbilityTargetEffect(DeathtouchAbility.getInstance(), Duration.EndOfTurn));
|
||||
Effect effect = new GainAbilityTargetEffect(DeathtouchAbility.getInstance(), Duration.EndOfTurn);
|
||||
effect.setOutcome(Outcome.Benefit);
|
||||
ability.addEffect(effect);
|
||||
ability.addTarget(new TargetCreaturePermanent());
|
||||
|
||||
// or Each opponent loses 1 life and you gain 1 life.
|
||||
Mode mode = new Mode();
|
||||
mode.addEffect(new LoseLifeOpponentsEffect(1));
|
||||
Effect effect = new GainLifeEffect(1);
|
||||
effect.setText("and you gain 1 life");
|
||||
mode.addEffect(effect);
|
||||
Effect gainLife = new GainLifeEffect(1);
|
||||
gainLife.setText("and you gain 1 life");
|
||||
mode.addEffect(gainLife);
|
||||
ability.addMode(mode);
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
|
|
@ -57,7 +57,7 @@ public final class SaskiaTheUnyielding extends CardImpl {
|
|||
class SaskiaTheUnyieldingEffect extends OneShotEffect {
|
||||
|
||||
public SaskiaTheUnyieldingEffect() {
|
||||
super(Outcome.Benefit);
|
||||
super(Outcome.Detriment);
|
||||
this.staticText = "it deals that much damage to the chosen player";
|
||||
}
|
||||
|
||||
|
|
|
@ -39,13 +39,15 @@ public final class ShieldedByFaith extends CardImpl {
|
|||
this.addAbility(new EnchantAbility(auraTarget.getTargetName()));
|
||||
|
||||
// Enchanted creature has indestructible.
|
||||
Effect effect = new GainAbilityAttachedEffect(IndestructibleAbility.getInstance(), AttachmentType.AURA, Duration.WhileOnBattlefield);
|
||||
Effect effect = new GainAbilityAttachedEffect(IndestructibleAbility.getInstance(),
|
||||
AttachmentType.AURA, Duration.WhileOnBattlefield);
|
||||
effect.setText("Enchanted creature has indestructible");
|
||||
effect.setOutcome(Outcome.Benefit);
|
||||
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect));
|
||||
|
||||
// Whenever a creature enters the battlefield, you may attach Shielded by Faith to that creature.
|
||||
this.addAbility(new EntersBattlefieldAllTriggeredAbility(
|
||||
Zone.BATTLEFIELD, new AttachEffect(Outcome.Neutral, "attach {source} to that creature"),
|
||||
Zone.BATTLEFIELD, new AttachEffect(Outcome.Benefit, "attach {source} to that creature"),
|
||||
new FilterCreaturePermanent("a creature"), true, SetTargetPointer.PERMANENT, null, false));
|
||||
}
|
||||
|
||||
|
|
|
@ -34,7 +34,7 @@ public final class SongOfTheDryads extends CardImpl {
|
|||
// Enchant permanent
|
||||
TargetPermanent auraTarget = new TargetPermanent();
|
||||
this.getSpellAbility().addTarget(auraTarget);
|
||||
this.getSpellAbility().addEffect(new AttachEffect(Outcome.Benefit));
|
||||
this.getSpellAbility().addEffect(new AttachEffect(Outcome.Detriment));
|
||||
Ability ability = new EnchantAbility(auraTarget.getTargetName());
|
||||
this.addAbility(ability);
|
||||
|
||||
|
@ -108,6 +108,8 @@ class BecomesColorlessForestLandEffect extends ContinuousEffectImpl {
|
|||
|
||||
@Override
|
||||
public boolean hasLayer(Layer layer) {
|
||||
return layer == Layer.AbilityAddingRemovingEffects_6 || layer == Layer.ColorChangingEffects_5 || layer == Layer.TypeChangingEffects_4;
|
||||
return layer == Layer.AbilityAddingRemovingEffects_6
|
||||
|| layer == Layer.ColorChangingEffects_5
|
||||
|| layer == Layer.TypeChangingEffects_4;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -56,8 +56,10 @@ public final class SurgicalExtraction extends CardImpl {
|
|||
class SurgicalExtractionEffect extends OneShotEffect {
|
||||
|
||||
public SurgicalExtractionEffect() {
|
||||
super(Outcome.Exile);
|
||||
this.staticText = "Choose target card in a graveyard other than a basic land card. Search its owner's graveyard, hand, and library for any number of cards with the same name as that card and exile them. Then that player shuffles their library";
|
||||
super(Outcome.Detriment);
|
||||
this.staticText = "Choose target card in a graveyard other than a basic land card. "
|
||||
+ "Search its owner's graveyard, hand, and library for any number of cards "
|
||||
+ "with the same name as that card and exile them. Then that player shuffles their library";
|
||||
}
|
||||
|
||||
public SurgicalExtractionEffect(final SurgicalExtractionEffect effect) {
|
||||
|
@ -80,21 +82,24 @@ class SurgicalExtractionEffect extends OneShotEffect {
|
|||
if (chosenCard != null && controller != null) {
|
||||
Player owner = game.getPlayer(chosenCard.getOwnerId());
|
||||
if (owner != null) {
|
||||
String nameToSearch = chosenCard.isSplitCard() ? ((SplitCard) chosenCard).getLeftHalfCard().getName() : chosenCard.getName();
|
||||
String nameToSearch = chosenCard.isSplitCard()
|
||||
? ((SplitCard) chosenCard).getLeftHalfCard().getName() : chosenCard.getName();
|
||||
FilterCard filterNamedCard = new FilterCard("card named " + nameToSearch);
|
||||
filterNamedCard.add(new NamePredicate(nameToSearch));
|
||||
|
||||
// cards in Graveyard
|
||||
int cardsCount = owner.getGraveyard().count(filterNamedCard, game);
|
||||
if (cardsCount > 0) {
|
||||
filterNamedCard.setMessage("card named " + nameToSearch + " in the graveyard of " + owner.getName());
|
||||
filterNamedCard.setMessage("card named " + nameToSearch
|
||||
+ " in the graveyard of " + owner.getName());
|
||||
TargetCardInGraveyard target = new TargetCardInGraveyard(0, cardsCount, filterNamedCard);
|
||||
if (controller.chooseTarget(Outcome.Exile, owner.getGraveyard(), target, source, game)) {
|
||||
List<UUID> targets = target.getTargets();
|
||||
for (UUID targetId : targets) {
|
||||
Card targetCard = owner.getGraveyard().get(targetId, game);
|
||||
if (targetCard != null) {
|
||||
controller.moveCardToExileWithInfo(targetCard, null, "", source.getSourceId(), game, Zone.GRAVEYARD, true);
|
||||
controller.moveCardToExileWithInfo(targetCard, null,
|
||||
"", source.getSourceId(), game, Zone.GRAVEYARD, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,5 +1,3 @@
|
|||
|
||||
|
||||
package mage.cards.s;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -33,16 +31,18 @@ import mage.target.common.TargetAnyTarget;
|
|||
public final class SwordOfFireAndIce extends CardImpl {
|
||||
|
||||
public SwordOfFireAndIce(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT},"{3}");
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT}, "{3}");
|
||||
this.subtype.add(SubType.EQUIPMENT);
|
||||
|
||||
// Equipped creature gets +2/+2 and has protection from red and from blue.
|
||||
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEquippedEffect(2, 2)));
|
||||
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(ProtectionAbility.from(ObjectColor.RED, ObjectColor.BLUE), AttachmentType.EQUIPMENT)));
|
||||
// Whenever equipped creature deals combat damage to a player, Sword of Fire and Ice deals 2 damage to any target and you draw a card.
|
||||
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(
|
||||
ProtectionAbility.from(ObjectColor.RED, ObjectColor.BLUE), AttachmentType.EQUIPMENT)));
|
||||
// Whenever equipped creature deals combat damage to a player, Sword of Fire
|
||||
// and Ice deals 2 damage to any target and you draw a card.
|
||||
this.addAbility(new SwordOfFireAndIceAbility());
|
||||
// Equip
|
||||
this.addAbility(new EquipAbility(Outcome.AddAbility, new GenericManaCost(2)));
|
||||
this.addAbility(new EquipAbility(Outcome.Benefit, new GenericManaCost(2)));
|
||||
}
|
||||
|
||||
public SwordOfFireAndIce(final SwordOfFireAndIce card) {
|
||||
|
@ -82,11 +82,14 @@ class SwordOfFireAndIceAbility extends TriggeredAbilityImpl {
|
|||
public boolean checkTrigger(GameEvent event, Game game) {
|
||||
DamagedPlayerEvent damageEvent = (DamagedPlayerEvent) event;
|
||||
Permanent p = game.getPermanent(event.getSourceId());
|
||||
return damageEvent.isCombatDamage() && p != null && p.getAttachments().contains(this.getSourceId());
|
||||
return damageEvent.isCombatDamage()
|
||||
&& p != null
|
||||
&& p.getAttachments().contains(this.getSourceId());
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getRule() {
|
||||
return "Whenever equipped creature deals combat damage to a player, {this} deals 2 damage to any target and you draw a card.";
|
||||
return "Whenever equipped creature deals combat damage to a player, "
|
||||
+ "{this} deals 2 damage to any target and you draw a card.";
|
||||
}
|
||||
}
|
||||
|
|
|
@ -6,7 +6,6 @@ import mage.constants.AbilityType;
|
|||
import mage.constants.Zone;
|
||||
import mage.game.Game;
|
||||
import mage.game.events.GameEvent;
|
||||
import mage.game.events.GameEvent.EventType;
|
||||
import mage.game.events.ZoneChangeEvent;
|
||||
import mage.players.Player;
|
||||
import mage.util.CardUtil;
|
||||
|
|
|
@ -39,7 +39,7 @@ public class DestroyTargetEffect extends OneShotEffect {
|
|||
}
|
||||
|
||||
public DestroyTargetEffect(boolean noRegen, boolean multitargetHandling) {
|
||||
super(Outcome.DestroyPermanent);
|
||||
super(Outcome.Detriment);
|
||||
this.noRegen = noRegen;
|
||||
this.multitargetHandling = multitargetHandling;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue