forked from External/mage
63 lines
2.2 KiB
Java
63 lines
2.2 KiB
Java
|
|
package mage.cards.s;
|
|
|
|
import java.util.UUID;
|
|
import mage.MageInt;
|
|
import mage.abilities.Ability;
|
|
import mage.abilities.common.SimpleActivatedAbility;
|
|
import mage.abilities.costs.common.SacrificeSourceCost;
|
|
import mage.abilities.costs.common.TapSourceCost;
|
|
import mage.abilities.costs.mana.GenericManaCost;
|
|
import mage.abilities.effects.Effect;
|
|
import mage.abilities.effects.common.ReturnToHandTargetEffect;
|
|
import mage.cards.CardImpl;
|
|
import mage.cards.CardSetInfo;
|
|
import mage.constants.CardType;
|
|
import mage.constants.SubType;
|
|
import mage.constants.Zone;
|
|
import mage.filter.FilterCard;
|
|
import mage.filter.predicate.Predicates;
|
|
import mage.filter.predicate.mageobject.CardTypePredicate;
|
|
import mage.target.common.TargetCardInYourGraveyard;
|
|
|
|
/**
|
|
*
|
|
* @author fireshoes
|
|
*/
|
|
public final class ScribeOfTheMindful extends CardImpl {
|
|
|
|
private static final FilterCard filter = new FilterCard("instant or sorcery card from your graveyard");
|
|
|
|
static {
|
|
filter.add(Predicates.or(
|
|
new CardTypePredicate(CardType.INSTANT),
|
|
new CardTypePredicate(CardType.SORCERY)));
|
|
}
|
|
|
|
public ScribeOfTheMindful(UUID ownerId, CardSetInfo setInfo) {
|
|
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{U}");
|
|
|
|
this.subtype.add(SubType.HUMAN);
|
|
this.subtype.add(SubType.CLERIC);
|
|
this.power = new MageInt(2);
|
|
this.toughness = new MageInt(2);
|
|
|
|
// {1}, {T}, Sacrifice Scribe of the Mindful: Return target instant or sorcery card from your graveyard to your hand.
|
|
Effect effect = new ReturnToHandTargetEffect();
|
|
effect.setText("Return target instant or sorcery card from your graveyard to your hand");
|
|
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new GenericManaCost(1));
|
|
ability.addCost(new TapSourceCost());
|
|
ability.addCost(new SacrificeSourceCost());
|
|
ability.addTarget(new TargetCardInYourGraveyard(filter));
|
|
this.addAbility(ability);
|
|
}
|
|
|
|
public ScribeOfTheMindful(final ScribeOfTheMindful card) {
|
|
super(card);
|
|
}
|
|
|
|
@Override
|
|
public ScribeOfTheMindful copy() {
|
|
return new ScribeOfTheMindful(this);
|
|
}
|
|
}
|