From 294567ec3e78423a62a56e70ef407fc7784e6553 Mon Sep 17 00:00:00 2001 From: LevelX2 Date: Tue, 25 Mar 2014 16:19:10 +0100 Subject: [PATCH] * Cycling effects - Added missing reveal effect, added missing reminder text. --- Mage.Sets/src/mage/sets/conflux/FieryFall.java | 6 +++++- .../search/SearchLibraryPutInHandEffect.java | 7 +++---- .../mage/abilities/keyword/CyclingAbility.java | 15 ++++++++------- 3 files changed, 16 insertions(+), 12 deletions(-) diff --git a/Mage.Sets/src/mage/sets/conflux/FieryFall.java b/Mage.Sets/src/mage/sets/conflux/FieryFall.java index 1432bc0c9d..33f22c972b 100644 --- a/Mage.Sets/src/mage/sets/conflux/FieryFall.java +++ b/Mage.Sets/src/mage/sets/conflux/FieryFall.java @@ -47,8 +47,12 @@ public class FieryFall extends CardImpl { super(ownerId, 63, "Fiery Fall", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{5}{R}"); this.expansionSetCode = "CON"; this.color.setRed(true); + + // Fiery Fall deals 5 damage to target creature. this.getSpellAbility().addEffect(new DamageTargetEffect(5)); - this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + this.getSpellAbility().addTarget(new TargetCreaturePermanent(true)); + + // Basic landcycling {1}{R} ({1}{R}, Discard this card: Search your library for a basic land card, reveal it, and put it into your hand. Then shuffle your library.) this.addAbility(new BasicLandcyclingAbility(new ManaCostsImpl("{1}{R}"))); } diff --git a/Mage/src/mage/abilities/effects/common/search/SearchLibraryPutInHandEffect.java b/Mage/src/mage/abilities/effects/common/search/SearchLibraryPutInHandEffect.java index eb35fa892d..0382db9234 100644 --- a/Mage/src/mage/abilities/effects/common/search/SearchLibraryPutInHandEffect.java +++ b/Mage/src/mage/abilities/effects/common/search/SearchLibraryPutInHandEffect.java @@ -28,15 +28,14 @@ package mage.abilities.effects.common.search; -import java.util.List; import java.util.UUID; -import mage.constants.Outcome; -import mage.constants.Zone; import mage.abilities.Ability; import mage.abilities.effects.SearchEffect; import mage.cards.Card; import mage.cards.Cards; import mage.cards.CardsImpl; +import mage.constants.Outcome; +import mage.constants.Zone; import mage.game.Game; import mage.players.Player; import mage.target.common.TargetCardInLibrary; @@ -93,7 +92,7 @@ public class SearchLibraryPutInHandEffect extends SearchEffect 0) { Cards cards = new CardsImpl(); - for (UUID cardId: (List)target.getTargets()) { + for (UUID cardId: target.getTargets()) { Card card = player.getLibrary().remove(cardId, game); if (card != null){ card.moveToZone(Zone.HAND, source.getId(), game, false); diff --git a/Mage/src/mage/abilities/keyword/CyclingAbility.java b/Mage/src/mage/abilities/keyword/CyclingAbility.java index 8fc5d1f3b6..697de3defe 100644 --- a/Mage/src/mage/abilities/keyword/CyclingAbility.java +++ b/Mage/src/mage/abilities/keyword/CyclingAbility.java @@ -45,8 +45,8 @@ import mage.target.common.TargetCardInLibrary; */ public class CyclingAbility extends ActivatedAbilityImpl { - private Cost cost; - private String text; + private final Cost cost; + private final String text; public CyclingAbility(Cost cost) { super(Zone.HAND, new DrawCardControllerEffect(1), cost); @@ -56,7 +56,7 @@ public class CyclingAbility extends ActivatedAbilityImpl { } public CyclingAbility(Cost cost, FilterCard filter, String text){ - super(Zone.HAND, new SearchLibraryPutInHandEffect(new TargetCardInLibrary(filter)), cost); + super(Zone.HAND, new SearchLibraryPutInHandEffect(new TargetCardInLibrary(filter), true, true), cost); this.addCost(new DiscardSourceCost()); this.cost = cost; this.text = text; @@ -75,14 +75,15 @@ public class CyclingAbility extends ActivatedAbilityImpl { @Override public String getRule() { - String rule; + StringBuilder rule = new StringBuilder(this.text); if(cost instanceof ManaCosts){ - rule = this.text + " " + cost.getText() + " (" + super.getRule() + ")"; + rule.append(" "); } else{ - rule = this.text + "-" + cost.getText() + " (" + super.getRule() + ")"; + rule.append(" - "); } - return rule; + rule.append(cost.getText()).append(" (").append(super.getRule(true)).append(")"); + return rule.toString(); } }