mirror of
https://github.com/correl/mage.git
synced 2024-11-15 19:19:33 +00:00
[minor] fixes
This commit is contained in:
parent
5a45c597bc
commit
5dd2a4a0c0
4 changed files with 20 additions and 40 deletions
|
@ -38,6 +38,7 @@ import mage.abilities.common.SimpleStaticAbility;
|
|||
import mage.abilities.effects.common.CantCounterControlledEffect;
|
||||
import mage.abilities.effects.common.CantCounterSourceEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.filter.Filter;
|
||||
import mage.filter.FilterSpell;
|
||||
|
||||
|
||||
|
@ -47,11 +48,12 @@ import mage.filter.FilterSpell;
|
|||
*/
|
||||
public class SpellbreakerBehemoth extends CardImpl<SpellbreakerBehemoth> {
|
||||
|
||||
private static FilterSpell filter = new FilterSpell("Creature spells you control with power 5 or greater");
|
||||
private static final FilterSpell filter = new FilterSpell("Creature spells you control with power 5 or greater");
|
||||
|
||||
static {
|
||||
filter.getCardType().add(CardType.CREATURE);
|
||||
filter.setPower(5);
|
||||
filter.setPower(4);
|
||||
filter.setPowerComparison(Filter.ComparisonType.GreaterThan);
|
||||
}
|
||||
|
||||
public SpellbreakerBehemoth(UUID ownerId) {
|
||||
|
|
|
@ -29,9 +29,10 @@ package mage.sets.darkascension;
|
|||
|
||||
import java.util.UUID;
|
||||
|
||||
import mage.Constants;
|
||||
import mage.Constants.CardType;
|
||||
import mage.Constants.Duration;
|
||||
import mage.Constants.Rarity;
|
||||
import mage.Constants.Zone;
|
||||
import mage.MageInt;
|
||||
import mage.abilities.common.SimpleStaticAbility;
|
||||
import mage.abilities.condition.common.MorbidCondition;
|
||||
|
@ -39,6 +40,7 @@ import mage.abilities.decorator.ConditionalContinousEffect;
|
|||
import mage.abilities.effects.common.continious.GainAbilityControlledEffect;
|
||||
import mage.abilities.keyword.VigilanceAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
|
||||
/**
|
||||
*
|
||||
|
@ -57,8 +59,8 @@ public class VillageSurvivors extends CardImpl<VillageSurvivors> {
|
|||
|
||||
this.addAbility(VigilanceAbility.getInstance());
|
||||
// Fateful hour - As long as you have 5 or less life, other creatures you control have vigilance.
|
||||
this.addAbility(new SimpleStaticAbility(Constants.Zone.BATTLEFIELD, new ConditionalContinousEffect(
|
||||
new GainAbilityControlledEffect(VigilanceAbility.getInstance(), Constants.Duration.WhileOnBattlefield),
|
||||
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(
|
||||
new GainAbilityControlledEffect(VigilanceAbility.getInstance(), Duration.WhileOnBattlefield, new FilterCreaturePermanent(), true),
|
||||
MorbidCondition.getInstance(),
|
||||
"Fateful hour - As long as you have 5 or less life, other creatures you control have vigilance")));
|
||||
}
|
||||
|
|
|
@ -31,18 +31,24 @@ import mage.Constants.CardType;
|
|||
import mage.Constants.Rarity;
|
||||
import mage.abilities.effects.common.DestroyTargetEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.filter.FilterPermanent;
|
||||
import mage.game.Game;
|
||||
import mage.game.permanent.Permanent;
|
||||
import mage.target.TargetPermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.filter.Filter;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
|
||||
/**
|
||||
* @author nantuko
|
||||
*/
|
||||
public class SmiteTheMonstrous extends CardImpl<SmiteTheMonstrous> {
|
||||
|
||||
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature with power 4 or greater");
|
||||
|
||||
static {
|
||||
filter.setPower(3);
|
||||
filter.setPowerComparison(Filter.ComparisonType.GreaterThan);
|
||||
}
|
||||
|
||||
public SmiteTheMonstrous(UUID ownerId) {
|
||||
super(ownerId, 33, "Smite the Monstrous", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{3}{W}");
|
||||
this.expansionSetCode = "ISD";
|
||||
|
@ -51,7 +57,7 @@ public class SmiteTheMonstrous extends CardImpl<SmiteTheMonstrous> {
|
|||
|
||||
// Destroy target creature with power 4 or greater.
|
||||
this.getSpellAbility().addEffect(new DestroyTargetEffect());
|
||||
this.getSpellAbility().addTarget(new TargetPermanent(new FilterTheMonstrous()));
|
||||
this.getSpellAbility().addTarget(new TargetPermanent(filter));
|
||||
}
|
||||
|
||||
public SmiteTheMonstrous(final SmiteTheMonstrous card) {
|
||||
|
@ -63,33 +69,3 @@ public class SmiteTheMonstrous extends CardImpl<SmiteTheMonstrous> {
|
|||
return new SmiteTheMonstrous(this);
|
||||
}
|
||||
}
|
||||
|
||||
class FilterTheMonstrous extends FilterPermanent<FilterTheMonstrous> {
|
||||
|
||||
public FilterTheMonstrous() {
|
||||
super("creature with power 4 or greater");
|
||||
}
|
||||
|
||||
public FilterTheMonstrous(FilterTheMonstrous filter) {
|
||||
super(filter);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean match(Permanent permanent, Game game) {
|
||||
if (!super.match(permanent, game))
|
||||
return notFilter;
|
||||
|
||||
if (!permanent.getCardType().contains(CardType.CREATURE))
|
||||
return notFilter;
|
||||
|
||||
if (permanent.getPower().getValue() < 4)
|
||||
return notFilter;
|
||||
|
||||
return !notFilter;
|
||||
}
|
||||
|
||||
@Override
|
||||
public FilterTheMonstrous copy() {
|
||||
return new FilterTheMonstrous(this);
|
||||
}
|
||||
}
|
|
@ -42,7 +42,7 @@ import mage.filter.common.FilterControlledPermanent;
|
|||
*/
|
||||
public class BountifulHarvest extends CardImpl<BountifulHarvest> {
|
||||
|
||||
private final static FilterControlledPermanent filter = new FilterControlledPermanent("land");
|
||||
private final static FilterControlledPermanent filter = new FilterControlledPermanent("land you control");
|
||||
|
||||
static {
|
||||
filter.getCardType().add(CardType.LAND);
|
||||
|
|
Loading…
Reference in a new issue