mirror of
https://github.com/correl/mage.git
synced 2024-11-15 19:19:33 +00:00
Implemented Keep Safe
This commit is contained in:
parent
3b69cf04f6
commit
c68616d572
2 changed files with 46 additions and 0 deletions
45
Mage.Sets/src/mage/cards/k/KeepSafe.java
Normal file
45
Mage.Sets/src/mage/cards/k/KeepSafe.java
Normal file
|
@ -0,0 +1,45 @@
|
||||||
|
package mage.cards.k;
|
||||||
|
|
||||||
|
import mage.abilities.effects.common.CounterTargetEffect;
|
||||||
|
import mage.abilities.effects.common.DrawCardSourceControllerEffect;
|
||||||
|
import mage.cards.CardImpl;
|
||||||
|
import mage.cards.CardSetInfo;
|
||||||
|
import mage.constants.CardType;
|
||||||
|
import mage.filter.FilterSpell;
|
||||||
|
import mage.filter.StaticFilters;
|
||||||
|
import mage.filter.predicate.other.TargetsPermanentPredicate;
|
||||||
|
import mage.target.TargetSpell;
|
||||||
|
|
||||||
|
import java.util.UUID;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author TheElk801
|
||||||
|
*/
|
||||||
|
public final class KeepSafe extends CardImpl {
|
||||||
|
|
||||||
|
private static final FilterSpell filter = new FilterSpell("spell that targets a permanent you control");
|
||||||
|
|
||||||
|
static {
|
||||||
|
filter.add(new TargetsPermanentPredicate(StaticFilters.FILTER_CONTROLLED_PERMANENT));
|
||||||
|
}
|
||||||
|
|
||||||
|
public KeepSafe(UUID ownerId, CardSetInfo setInfo) {
|
||||||
|
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{1}{U}");
|
||||||
|
|
||||||
|
// Counter target spell that targets a permanent you control.
|
||||||
|
this.getSpellAbility().addEffect(new CounterTargetEffect());
|
||||||
|
this.getSpellAbility().addTarget(new TargetSpell(filter));
|
||||||
|
|
||||||
|
// Draw a card.
|
||||||
|
this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(1));
|
||||||
|
}
|
||||||
|
|
||||||
|
private KeepSafe(final KeepSafe card) {
|
||||||
|
super(card);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public KeepSafe copy() {
|
||||||
|
return new KeepSafe(this);
|
||||||
|
}
|
||||||
|
}
|
|
@ -104,6 +104,7 @@ public final class IkoriaLairOfBehemoths extends ExpansionSet {
|
||||||
cards.add(new SetCardInfo("Huntmaster Liger", 16, Rarity.UNCOMMON, mage.cards.h.HuntmasterLiger.class));
|
cards.add(new SetCardInfo("Huntmaster Liger", 16, Rarity.UNCOMMON, mage.cards.h.HuntmasterLiger.class));
|
||||||
cards.add(new SetCardInfo("Indatha Crystal", 235, Rarity.UNCOMMON, mage.cards.i.IndathaCrystal.class));
|
cards.add(new SetCardInfo("Indatha Crystal", 235, Rarity.UNCOMMON, mage.cards.i.IndathaCrystal.class));
|
||||||
cards.add(new SetCardInfo("Insatiable Hemophage", 93, Rarity.UNCOMMON, mage.cards.i.InsatiableHemophage.class));
|
cards.add(new SetCardInfo("Insatiable Hemophage", 93, Rarity.UNCOMMON, mage.cards.i.InsatiableHemophage.class));
|
||||||
|
cards.add(new SetCardInfo("Keep Safe", 56, Rarity.COMMON, mage.cards.k.KeepSafe.class));
|
||||||
cards.add(new SetCardInfo("Ketria Crystal", 236, Rarity.UNCOMMON, mage.cards.k.KetriaCrystal.class));
|
cards.add(new SetCardInfo("Ketria Crystal", 236, Rarity.UNCOMMON, mage.cards.k.KetriaCrystal.class));
|
||||||
cards.add(new SetCardInfo("Kogla, the Titan Ape", 162, Rarity.RARE, mage.cards.k.KoglaTheTitanApe.class));
|
cards.add(new SetCardInfo("Kogla, the Titan Ape", 162, Rarity.RARE, mage.cards.k.KoglaTheTitanApe.class));
|
||||||
cards.add(new SetCardInfo("Lore Drakkis", 194, Rarity.UNCOMMON, mage.cards.l.LoreDrakkis.class));
|
cards.add(new SetCardInfo("Lore Drakkis", 194, Rarity.UNCOMMON, mage.cards.l.LoreDrakkis.class));
|
||||||
|
|
Loading…
Reference in a new issue