1
0
Fork 0
mirror of https://github.com/correl/mage.git synced 2025-03-13 01:09:53 -09:00

* Explosive Revelation and Drown In Filth - Targets are mandatory now.

This commit is contained in:
LevelX2 2013-06-14 15:20:34 +02:00
parent 6c546220a3
commit 6eebe83b20
2 changed files with 5 additions and 24 deletions
Mage.Sets/src/mage/sets

View file

@ -55,7 +55,7 @@ public class DrownInFilth extends CardImpl<DrownInFilth> {
this.color.setBlack(true);
// Choose target creature. Put the top four cards of your library into your graveyard, then that creature gets -1/-1 until end of turn for each land card in your graveyard.
this.getSpellAbility().addTarget(new TargetCreaturePermanent());
this.getSpellAbility().addTarget(new TargetCreaturePermanent(true));
Effect effect = new PutTopCardOfYourLibraryIntoGraveEffect(4);
effect.setText("Choose target creature. Put the top four cards of your library into your graveyard");
this.getSpellAbility().addEffect(effect);

View file

@ -36,12 +36,10 @@ import mage.abilities.effects.OneShotEffect;
import mage.cards.Card;
import mage.cards.CardImpl;
import mage.cards.CardsImpl;
import mage.filter.FilterCard;
import mage.game.Game;
import mage.game.permanent.Permanent;
import mage.players.Library;
import mage.players.Player;
import mage.target.TargetCard;
import mage.target.common.TargetCreatureOrPlayer;
/**
@ -58,7 +56,7 @@ public class ExplosiveRevelation extends CardImpl<ExplosiveRevelation> {
// Choose target creature or player. Reveal cards from the top of your library until you reveal a nonland card. Explosive Revelation deals damage equal to that card's converted mana cost to that creature or player. Put the nonland card into your hand and the rest on the bottom of your library in any order.
this.getSpellAbility().addEffect(new ExplosiveRevelationEffect());
this.getSpellAbility().addTarget(new TargetCreatureOrPlayer());
this.getSpellAbility().addTarget(new TargetCreatureOrPlayer(true));
}
public ExplosiveRevelation(final ExplosiveRevelation card) {
@ -75,7 +73,7 @@ class ExplosiveRevelationEffect extends OneShotEffect<ExplosiveRevelationEffect>
public ExplosiveRevelationEffect() {
super(Constants.Outcome.DrawCard);
this.staticText = "Reveal cards from the top of your library until you reveal a nonland card, {this} deals damage equal to that card's converted mana cost to that creature or player. Put the nonland card into your hand and the rest on the bottom of your library in any order.";
this.staticText = "Choose target creature or player. Reveal cards from the top of your library until you reveal a nonland card, {this} deals damage equal to that card's converted mana cost to that creature or player. Put the nonland card into your hand and the rest on the bottom of your library in any order";
}
public ExplosiveRevelationEffect(final ExplosiveRevelationEffect effect) {
@ -123,25 +121,8 @@ class ExplosiveRevelationEffect extends OneShotEffect<ExplosiveRevelationEffect>
card.moveToZone(Constants.Zone.HAND, id, game, true);
// remove nonland card from revealed card list
cards.remove(card);
// put the rest of the cards into the bottom of the library in any order
if (cards.size() != 0) {
TargetCard target = new TargetCard(Constants.Zone.PICK, new FilterCard("card to put on the bottom of your library"));
target.setRequired(true);
while (cards.size() > 1) {
player.choose(Constants.Outcome.Neutral, cards, target, game);
Card chosenCard = cards.get(target.getFirstTarget(), game);
if (chosenCard != null) {
cards.remove(card);
chosenCard.moveToZone(Constants.Zone.LIBRARY, id, game, false);
}
target.clearChosen();
}
if (cards.size() == 1) {
Card chosenCard = cards.get(cards.iterator().next(), game);
chosenCard.moveToZone(Constants.Zone.LIBRARY, id, game, false);
}
}
return true;
// put the rest of the cards on the bottom of the library in any order
return player.putCardsOnBottomOfLibrary(cards, game, source, true);
}
return false;
}