Package mage.abilities.condition.common

Examples of mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition


        // {W}, {tap}: Put target card from your graveyard on the bottom of your library. Activate this ability only if you control two or more white permanents.
        Ability ability = new ActivateIfConditionActivatedAbility(
                Zone.BATTLEFIELD,
                new MistveilPlainsGraveyardToLibraryEffect(),
                new ManaCostsImpl("{W}"),
                new PermanentsOnTheBattlefieldCondition(filter, PermanentsOnTheBattlefieldCondition.CountType.MORE_THAN, 1));
        ability.addTarget(new TargetCardInYourGraveyard());
        ability.addCost(new TapSourceCost());
        this.addAbility(ability);

    }
View Full Code Here


    public SulfurFalls(UUID ownerId) {
        super(ownerId, 248, "Sulfur Falls", Rarity.RARE, new CardType[]{CardType.LAND}, null);
        this.expansionSetCode = "ISD";

        Condition controls = new InvertCondition(new PermanentsOnTheBattlefieldCondition(filter, PermanentsOnTheBattlefieldCondition.CountType.MORE_THAN, 0));
        String abilityText = "tap it unless you control a Island or a Mountain";
        this.addAbility(new EntersBattlefieldAbility(new ConditionalOneShotEffect(new TapSourceEffect(), controls, abilityText), abilityText));
        this.addAbility(new BlueManaAbility());
        this.addAbility(new RedManaAbility());
    }
View Full Code Here

        // Flying
        this.addAbility(FlyingAbility.getInstance());
       
        // Briarberry Cohort gets +1/+1 as long as you control another blue creature.
        Condition condition = new PermanentsOnTheBattlefieldCondition(filter, CountType.MORE_THAN, 0);
        Effect effect = new ConditionalContinousEffect(new BoostSourceEffect(1, 1, Duration.WhileOnBattlefield), condition, rule);
        this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect));
       
    }
View Full Code Here

        // As long as Brawn is in your graveyard and you control a Forest, creatures you control have trample
        ContinuousEffect effect = new GainAbilityControlledEffect(TrampleAbility.getInstance(),
                Duration.WhileOnBattlefield, new FilterCreaturePermanent());
        ConditionalContinousEffect brawnEffect = new ConditionalContinousEffect(effect,
                new PermanentsOnTheBattlefieldCondition(filter), ruleText);
        this.addAbility(new SimpleStaticAbility(Zone.GRAVEYARD, brawnEffect));
    }
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

        this.toughness = new MageInt(3);

        // Marauding Maulhorn attacks each combat if able unless you control a creature named Advocate of the Beast.
        Effect effect = new ConditionalRequirementEffect(
                new AttacksIfAbleSourceEffect(Duration.WhileOnBattlefield),
                new PermanentsOnTheBattlefieldCondition(filter, PermanentsOnTheBattlefieldCondition.CountType.FEWER_THAN, 1));
        effect.setText("{this} attacks each combat if able unless you control a creature named Advocate of the Beast");

        this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect));
       
    }
View Full Code Here

        this.toughness = new MageInt(1);

        // As long as you control a Giant, Kithkin Greatheart gets +1/+1 and has first strike.
        Ability ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(
                new BoostSourceEffect(1,1, Duration.WhileOnBattlefield),
                new PermanentsOnTheBattlefieldCondition(filter),
                "As long as you control a Giant, Kithkin Greatheart gets +1/+1"));
        this.addAbility(ability);
        ConditionalContinousEffect effect2 = new ConditionalContinousEffect(
                new GainAbilitySourceEffect(FirstStrikeAbility.getInstance())
                new PermanentsOnTheBattlefieldCondition(filter),
                rule2);
        this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect2));

    }
View Full Code Here

        this.expansionSetCode = "AVR";

        // {1}, Sacrifice Scroll of Griselbrand: Target opponent discards a card. If you control a Demon, that player loses 3 life.
        Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DiscardTargetEffect(1), new GenericManaCost(1));
        ability.addCost(new SacrificeSourceCost());
        ability.addEffect(new ConditionalOneShotEffect(new LoseLifeTargetEffect(3), new PermanentsOnTheBattlefieldCondition(filter), "If you control a Demon, that player loses 3 life"));
        ability.addTarget(new TargetOpponent());
        this.addAbility(ability);
    }
View Full Code Here

        this.toughness = new MageInt(3);

        // Kird Chieftain gets +1/+1 as long as you control a Forest.
        this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD,
                new ConditionalContinousEffect(new BoostSourceEffect(1, 1, Duration.WhileOnBattlefield),
                new PermanentsOnTheBattlefieldCondition(filter), rule)));
       
        // {4}{G}: Target creature gets +2/+2 and gains trample until end of turn.
        Effect effect = new BoostTargetEffect(2, 2, Duration.EndOfTurn);
        effect.setText("Target creature gets +2/+2");
        Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new ManaCostsImpl("{4}{G}"));
View Full Code Here

        // First strike
        this.addAbility(FirstStrikeAbility.getInstance());
       
        // Ballynock Cohort gets +1/+1 as long as you control another white creature.
        Condition condition = new PermanentsOnTheBattlefieldCondition(filter, CountType.MORE_THAN, 0);
        Effect effect = new ConditionalContinousEffect(new BoostSourceEffect(1, 1, Duration.WhileOnBattlefield), condition, rule);
        this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect));
       
    }
View Full Code Here

TOP

Related Classes of mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition

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.