mirror of
https://github.com/correl/mage.git
synced 2024-12-25 19:25:41 +00:00
Standardise use of CantBeCounteredSourceAbility for remaining cards not yet using it
This commit is contained in:
parent
a4b4965779
commit
fc560d4853
6 changed files with 17 additions and 63 deletions
|
@ -2,16 +2,12 @@
|
|||
package mage.cards.a;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.SimpleStaticAbility;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.CantBeCounteredSourceEffect;
|
||||
import mage.abilities.common.CantBeCounteredSourceAbility;
|
||||
import mage.abilities.effects.common.DestroyTargetEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.ComparisonType;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.common.FilterNonlandPermanent;
|
||||
import mage.filter.predicate.mageobject.ManaValuePredicate;
|
||||
import mage.target.common.TargetNonlandPermanent;
|
||||
|
@ -31,12 +27,8 @@ public final class AbruptDecay extends CardImpl {
|
|||
public AbruptDecay(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{B}{G}");
|
||||
|
||||
// Abrupt Decay can't be countered.
|
||||
Effect effect = new CantBeCounteredSourceEffect();
|
||||
effect.setText("this spell can't be countered");
|
||||
Ability ability = new SimpleStaticAbility(Zone.STACK, effect);
|
||||
ability.setRuleAtTheTop(true);
|
||||
this.addAbility(ability);
|
||||
// This spell can't be countered.
|
||||
this.addAbility(new CantBeCounteredSourceAbility());
|
||||
|
||||
// Destroy target nonland permanent with converted mana cost 3 or less.
|
||||
this.getSpellAbility().addEffect(new DestroyTargetEffect());
|
||||
|
|
|
@ -2,16 +2,12 @@
|
|||
package mage.cards.o;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.SimpleStaticAbility;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.CantBeCounteredSourceEffect;
|
||||
import mage.abilities.common.CantBeCounteredSourceAbility;
|
||||
import mage.abilities.effects.common.CounterTargetEffect;
|
||||
import mage.abilities.keyword.SurgeAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Zone;
|
||||
import mage.target.TargetSpell;
|
||||
|
||||
/**
|
||||
|
@ -23,12 +19,8 @@ public final class OverwhelmingDenial extends CardImpl {
|
|||
public OverwhelmingDenial(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{2}{U}{U}");
|
||||
|
||||
// Overwhelming Denial can't be countered by spell or abilities.
|
||||
Effect effect = new CantBeCounteredSourceEffect();
|
||||
effect.setText("this spell can't be countered");
|
||||
Ability ability = new SimpleStaticAbility(Zone.STACK, effect);
|
||||
ability.setRuleAtTheTop(true);
|
||||
this.addAbility(ability);
|
||||
// This spell can't be countered.
|
||||
this.addAbility(new CantBeCounteredSourceAbility());
|
||||
|
||||
// Counter target spell.
|
||||
this.getSpellAbility().addTarget(new TargetSpell());
|
||||
|
|
|
@ -1,15 +1,12 @@
|
|||
package mage.cards.r;
|
||||
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.SimpleStaticAbility;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.common.CantBeCounteredSourceAbility;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.common.CantBeCounteredSourceEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.Zone;
|
||||
import mage.game.Game;
|
||||
import mage.game.permanent.Permanent;
|
||||
import mage.players.Player;
|
||||
|
@ -26,11 +23,7 @@ public final class RazeToTheGround extends CardImpl {
|
|||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{2}{R}");
|
||||
|
||||
// This spell can't be countered.
|
||||
Effect effect = new CantBeCounteredSourceEffect();
|
||||
effect.setText("this spell can't be countered");
|
||||
Ability ability = new SimpleStaticAbility(Zone.STACK, effect);
|
||||
ability.setRuleAtTheTop(true);
|
||||
this.addAbility(ability);
|
||||
this.addAbility(new CantBeCounteredSourceAbility());
|
||||
|
||||
// Destroy target artifact. If its mana value was 1 or less, draw a card.
|
||||
this.getSpellAbility().addEffect(new RazeToTheGroundEffect());
|
||||
|
|
|
@ -1,15 +1,12 @@
|
|||
package mage.cards.s;
|
||||
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.SimpleStaticAbility;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.CantBeCounteredSourceEffect;
|
||||
import mage.abilities.common.CantBeCounteredSourceAbility;
|
||||
import mage.abilities.effects.common.ChooseACardNameEffect;
|
||||
import mage.abilities.effects.common.search.SearchTargetGraveyardHandLibraryForCardNameAndExileEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Zone;
|
||||
import mage.game.Game;
|
||||
import mage.target.common.TargetOpponent;
|
||||
|
||||
|
@ -23,12 +20,8 @@ public final class SlaughterGames extends CardImpl {
|
|||
public SlaughterGames(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{2}{B}{R}");
|
||||
|
||||
// Slaughter Games can't be countered.
|
||||
Effect effect = new CantBeCounteredSourceEffect();
|
||||
effect.setText("this spell can't be countered");
|
||||
Ability ability = new SimpleStaticAbility(Zone.STACK, effect);
|
||||
ability.setRuleAtTheTop(true);
|
||||
this.addAbility(ability);
|
||||
// This spell can't be countered.
|
||||
this.addAbility(new CantBeCounteredSourceAbility());
|
||||
|
||||
// Name a nonland card. Search target opponent's graveyard, hand, and library for any number of cards with that name and exile them. Then that player shuffles their library.
|
||||
this.getSpellAbility().addEffect(new ChooseACardNameEffect(ChooseACardNameEffect.TypeOfName.NON_LAND_NAME));
|
||||
|
|
|
@ -2,16 +2,12 @@
|
|||
package mage.cards.t;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.SimpleStaticAbility;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.CantBeCounteredSourceEffect;
|
||||
import mage.abilities.common.CantBeCounteredSourceAbility;
|
||||
import mage.abilities.effects.common.DamageTargetEffect;
|
||||
import mage.abilities.keyword.FlyingAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
import mage.filter.predicate.mageobject.AbilityPredicate;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
|
@ -31,12 +27,8 @@ public final class TearsOfValakut extends CardImpl {
|
|||
public TearsOfValakut(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{1}{R}");
|
||||
|
||||
// Tears of Valakut can't be countered.
|
||||
Effect effect = new CantBeCounteredSourceEffect();
|
||||
effect.setText("this spell can't be countered");
|
||||
Ability ability = new SimpleStaticAbility(Zone.STACK, effect);
|
||||
ability.setRuleAtTheTop(true);
|
||||
this.addAbility(ability);
|
||||
// This spell can't be countered.
|
||||
this.addAbility(new CantBeCounteredSourceAbility());
|
||||
|
||||
// Tears of Valakut deals 5 damage to target creature with flying.
|
||||
this.getSpellAbility().addEffect(new DamageTargetEffect(5));
|
||||
|
|
|
@ -1,17 +1,13 @@
|
|||
package mage.cards.u;
|
||||
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.SimpleStaticAbility;
|
||||
import mage.abilities.common.CantBeCounteredSourceAbility;
|
||||
import mage.abilities.condition.common.KickedCondition;
|
||||
import mage.abilities.decorator.ConditionalOneShotEffect;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.CantBeCounteredSourceEffect;
|
||||
import mage.abilities.effects.common.DamageTargetEffect;
|
||||
import mage.abilities.keyword.KickerAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Zone;
|
||||
import mage.target.common.TargetAnyTarget;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -27,12 +23,8 @@ public final class UrzasRage extends CardImpl {
|
|||
// Kicker {8}{R}
|
||||
this.addAbility(new KickerAbility("{8}{R}"));
|
||||
|
||||
// Urza's Rage can't be countered.
|
||||
Effect effect = new CantBeCounteredSourceEffect();
|
||||
effect.setText("this spell can't be countered");
|
||||
Ability ability = new SimpleStaticAbility(Zone.STACK, effect);
|
||||
ability.setRuleAtTheTop(true);
|
||||
this.addAbility(ability);
|
||||
// This spell can't be countered.
|
||||
this.addAbility(new CantBeCounteredSourceAbility());
|
||||
|
||||
// Urza's Rage deals 3 damage to any target. If Urza's Rage was kicked, instead it deals 10 damage to that creature or player and the damage can't be prevented.
|
||||
this.getSpellAbility().addEffect(new ConditionalOneShotEffect(
|
||||
|
|
Loading…
Reference in a new issue