* Cycling effects - Added missing reveal effect, added missing reminder text.

This commit is contained in:
LevelX2 2014-03-25 16:19:10 +01:00
parent 5a54488a0d
commit 294567ec3e
3 changed files with 16 additions and 12 deletions

View file

@ -47,8 +47,12 @@ public class FieryFall extends CardImpl<FieryFall> {
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}")));
}

View file

@ -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<SearchLibraryPutI
if (player.searchLibrary(target, game)) {
if (target.getTargets().size() > 0) {
Cards cards = new CardsImpl();
for (UUID cardId: (List<UUID>)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);

View file

@ -45,8 +45,8 @@ import mage.target.common.TargetCardInLibrary;
*/
public class CyclingAbility extends ActivatedAbilityImpl<CyclingAbility> {
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<CyclingAbility> {
}
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<CyclingAbility> {
@Override
public String getRule() {
String rule;
StringBuilder rule = new StringBuilder(this.text);
if(cost instanceof ManaCosts){
rule = this.text + " " + cost.getText() + " <i>(" + super.getRule() + ")</i>";
rule.append(" ");
}
else{
rule = this.text + "-" + cost.getText() + " <i>(" + super.getRule() + ")</i>";
rule.append(" - ");
}
return rule;
rule.append(cost.getText()).append(" <i>(").append(super.getRule(true)).append(")</i>");
return rule.toString();
}
}