Package mage.abilities.condition

Examples of mage.abilities.condition.InvertCondition


        // Flying
        this.addAbility(FlyingAbility.getInstance());

        // When Sphinx of Lost Truths enters the battlefield, draw three cards. Then if it wasn't kicked, discard three cards.
        Ability ability = new EntersBattlefieldTriggeredAbility(new DrawCardSourceControllerEffect(3));
        ability.addEffect(new ConditionalOneShotEffect(new DiscardControllerEffect(3), new InvertCondition(KickedCondition.getInstance()),
                "Then if it wasn't kicked, discard three cards"));
        this.addAbility(ability);
    }
View Full Code Here


        this.toughness = new MageInt(2);

        this.addAbility(new BeginningOfUpkeepTriggeredAbility(
            new ConditionalOneShotEffect(
                    new LoseLifeSourceControllerEffect(1),
                    new InvertCondition( new TenOrLessLifeCondition(TenOrLessLifeCondition.CheckType.AN_OPPONENT) ),
                    "you lose 1 life unless an opponent has 10 or less life"), TargetController.YOU, false));
    }
View Full Code Here

        this.toughness = new MageInt(1);

        // Giant Tortoise gets +0/+3 as long as it's untapped.
        this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(
                new BoostSourceEffect(0,3, Duration.WhileOnBattlefield),
                new InvertCondition(new SourceTappedCondition()),
                "{this} gets +0/+3 as long as it's untapped")));
    }
View Full Code Here

    public DarkslickShores (UUID ownerId) {
        super(ownerId, 226, "Darkslick Shores", Rarity.RARE, new CardType[]{CardType.LAND}, null);
        this.expansionSetCode = "SOM";

        // Darkslick Shores enters the battlefield tapped unless you control two or fewer other lands.
        Condition controls = new InvertCondition(new PermanentsOnTheBattlefieldCondition(filter, PermanentsOnTheBattlefieldCondition.CountType.FEWER_THAN, 3));
        String abilityText = "tapped unless you control two or fewer other lands";
        this.addAbility(new EntersBattlefieldAbility(new ConditionalOneShotEffect(new TapSourceEffect(), controls, abilityText), abilityText));
       
        this.addAbility(new BlueManaAbility());
        this.addAbility(new BlackManaAbility());
View Full Code Here

        this.addWatcher(new CastFromHandWatcher());

        // Epochrasite enters the battlefield with three +1/+1 counters on it if you didn't cast it from your hand.
        this.addAbility(new EntersBattlefieldAbility(
                    new AddCountersSourceEffect(CounterType.P1P1.createInstance(3)),
                    new InvertCondition(new CastFromHandCondition()), true,
                    "{this} enters the battlefield with three +1/+1 counters on it if you didn't cast it from your hand",""));

        // When Epochrasite dies, exile it with three time counters on it and it gains suspend.
        Ability ability = new DiesTriggeredAbility(new ExileSourceEffect());
        ability.addEffect(new AddCountersSourceEffect(CounterType.TIME.createInstance(3), new StaticValue(0), false, true));
View Full Code Here

        ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(
                new GainAbilityAttachedEffect(DoubleStrikeAbility.getInstance(), AttachmentType.AURA, Duration.WhileOnBattlefield),
                condition, "Enchanted creature has double strike as long as it's an enchantment"));
        ReplacementEffect effect = new PreventAllDamageByAttachedEffect(Duration.WhileOnBattlefield, "enchanted creature", false);
        effect.setText("Otherwise, prevent all damage that would be dealt by enchanted creature");
        ability.addEffect(new ConditionalReplacementEffect(effect, new InvertCondition(condition)));
        this.addAbility(ability);
    }
View Full Code Here

        // {tap}: Add {1} to your mana pool.
        this.addAbility(new ColorlessManaAbility());
       
        // {0}: Return Ghost Town to its owner's hand. Activate this ability only if it's not your turn.
        this.addAbility(new ActivateIfConditionActivatedAbility(Zone.BATTLEFIELD, new ReturnToHandSourceEffect(true), new GenericManaCost(0), new InvertCondition(MyTurnCondition.getInstance())));
    }
View Full Code Here

    public IsolatedChapel(UUID ownerId) {
        super(ownerId, 242, "Isolated Chapel", 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 Plains or a Swamp";
        this.addAbility(new EntersBattlefieldAbility(new ConditionalOneShotEffect(new TapSourceEffect(), controls, abilityText), abilityText));
        this.addAbility(new WhiteManaAbility());
        this.addAbility(new BlackManaAbility());
    }
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

        target = new TargetControlledCreaturePermanent();
        target.setNotTarget(false);
        triggeredAbility.addTarget(target);
        this.addAbility(new ConditionalTriggeredAbility(
                triggeredAbility,
                new InvertCondition(new CreatureCardsInControllerGraveCondition(6)),
                "At the beginning of your upkeep, if there are fewer than six creature cards in your graveyard, sacrifice a creature"));

    }
View Full Code Here

TOP

Related Classes of mage.abilities.condition.InvertCondition

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.