Package mage.filter.common

Examples of mage.filter.common.FilterLandPermanent


        assertPermanentCount(playerA, "Silvercoat Lion", 1); // was indestructible
        assertPermanentCount(playerA, "Black Knight", 1);
        assertTapped("Silvercoat Lion", true);
        assertTapped("Black Knight", true);

        for (Permanent permanent: currentGame.getBattlefield().getAllActivePermanents(new FilterLandPermanent(), playerA.getId(), currentGame)) {
            Assert.assertTrue(permanent.getName() + " may not be tapped", !permanent.isTapped());
        }
    }
View Full Code Here


        this.power = new MageInt(3);
        this.toughness = new MageInt(3);

        // Whenever a land enters the battlefield under your control, put a 1/1 green Saproling creature token onto the battlefield.
        Effect effect = new CreateTokenEffect(new SaprolingToken());
        this.addAbility(new EntersBattlefieldControlledTriggeredAbility(effect, new FilterLandPermanent("a land")));
    }
View Full Code Here

        ability.addTarget(new TargetControlledCreaturePermanent());
        this.addAbility(ability);

        // Whenever a land enters the battlefield under your control, you gain 3 life.
        effect = new GainLifeEffect(3);
        ability = new EntersBattlefieldControlledTriggeredAbility(effect, new FilterLandPermanent("a land"));
        this.addAbility(ability);

    }
View Full Code Here

* @author BetaSteward_at_googlemail.com
*/
public class TargetLandPermanent extends TargetPermanent {

    public TargetLandPermanent() {
        this(1, 1, new FilterLandPermanent(), false);
    }
View Full Code Here

    public TargetLandPermanent(FilterLandPermanent filter) {
        this(1, 1, filter, false);
    }

    public TargetLandPermanent(int numTargets) {
        this(numTargets, numTargets, new FilterLandPermanent(), false);
    }
View Full Code Here

    return new StormtideLeviathanEffect(this);
  }

  @Override
  public boolean apply(Game game, Ability source) {
    for (Permanent permanent: game.getBattlefield().getActivePermanents(new FilterLandPermanent(), source.getControllerId(), game)) {
      if (!permanent.getSubtype().contains("Island"))
        permanent.getSubtype().add("Island");
    }
    return true;
  }
View Full Code Here

    public StoneRain (UUID ownerId) {
        super(ownerId, 206, "Stone Rain", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{2}{R}");
        this.expansionSetCode = "TMP";
        this.color.setRed(true);
        this.getSpellAbility().addTarget(new TargetPermanent(new FilterLandPermanent()));
        this.getSpellAbility().addEffect(new DestroyTargetEffect());
    }
View Full Code Here

    }

    @Override
    public boolean apply(Game game, Ability source) {
        if (targetPointer != null) {
            for(Permanent permanent : game.getBattlefield().getAllActivePermanents(new FilterLandPermanent(), targetPointer.getFirst(game, source), game)){
                if (permanent != null) {
                    permanent.changeControllerId(source.getControllerId(), game);
                }
            }
        }
View Full Code Here

}

class CandelabraOfTawnosAbility extends ActivatedAbilityImpl implements AdjustingSourceCosts{
    public CandelabraOfTawnosAbility(){
        super(Zone.BATTLEFIELD, new UntapTargetEffect(), new TapSourceCost());
        addTarget(new TargetLandPermanent(0, Integer.MAX_VALUE, new FilterLandPermanent(), false));
    }
View Full Code Here

        this.color.setGreen(true);
        this.power = new MageInt(4);
        this.toughness = new MageInt(4);

        // As long as you control eight or more lands, Woodborn Behemoth gets +4/+4 and has trample.
        PermanentsOnTheBattlefieldCondition eightOrMoreLandCondition = new PermanentsOnTheBattlefieldCondition(new FilterLandPermanent(), PermanentsOnTheBattlefieldCondition.CountType.MORE_THAN,7);
        ConditionalContinousEffect effect1 = new ConditionalContinousEffect(
                new BoostSourceEffect(4,4, Duration.WhileOnBattlefield), eightOrMoreLandCondition,
                "As long as you control eight or more lands, {this} gets +4/+4");
        ConditionalContinousEffect effect2 = new ConditionalContinousEffect(
                new GainAbilitySourceEffect(TrampleAbility.getInstance(), Duration.WhileOnBattlefield),
View Full Code Here

TOP

Related Classes of mage.filter.common.FilterLandPermanent

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.