Package mage.abilities

Examples of mage.abilities.Mode


        //Choose one - Counter target sorcery spell
        this.getSpellAbility().addEffect(new CounterTargetEffect());
        this.getSpellAbility().addTarget(new TargetSpell(filterSorcery));

        //or destroy target creature with power 2 or less
        Mode mode1 = new Mode();
        mode1.getEffects().add(new DestroyTargetEffect());
        mode1.getTargets().add(new TargetCreaturePermanent(filterCreature));
        this.getSpellAbility().addMode(mode1);

        //or look at the top three cards of target player's library, then put one back and the rest into that player's graveyard
        Mode mode2 = new Mode();
        mode2.getEffects().add(new DimirCharmEffect());
        mode2.getTargets().add(new TargetPlayer());
        this.getSpellAbility().addMode(mode2);
    }
View Full Code Here


        this.color.setBlack(true);

        // Choose one - Target player draws two cards; or target player discards two cards.
        this.getSpellAbility().addTarget(new TargetPlayer());
        this.getSpellAbility().addEffect(new DrawCardTargetEffect(2));
        Mode mode = new Mode();
        mode.getTargets().add(new TargetPlayer());
        mode.getEffects().add(new DiscardTargetEffect(2));
        this.getSpellAbility().addMode(mode);
    }
View Full Code Here

        this.color.setWhite(true);

        // Choose one - Prevent all combat damage that would be dealt this turn; or regenerate target creature; or counter target spell that targets you.
        this.getSpellAbility().addEffect(new PreventAllDamageByAllEffect(Duration.EndOfTurn));

        Mode mode = new Mode();
        mode.getEffects().add(new RegenerateTargetEffect());
        mode.getTargets().add(new TargetCreaturePermanent());
        this.getSpellAbility().addMode(mode);

        mode = new Mode();
        mode.getEffects().add(new CounterTargetEffect());
        mode.getTargets().add(new TargetSpell(filter));
        this.getSpellAbility().addMode(mode);
    }
View Full Code Here

        // Choose one - Target creature gains islandwalk until end of turn;
        this.getSpellAbility().addEffect(new GainAbilityTargetEffect(new IslandwalkAbility(), Duration.EndOfTurn));
        this.getSpellAbility().addTarget(new TargetCreaturePermanent());
        // or target creature gets +2/-1 until end of turn;
        Mode mode = new Mode();
        mode.getEffects().add(new BoostTargetEffect(2, -1, Duration.EndOfTurn));
        mode.getTargets().add(new TargetCreaturePermanent());
        this.getSpellAbility().addMode(mode);
        // or target player discards a card.
        mode = new Mode();
        mode.getEffects().add(new DiscardTargetEffect(1));
        mode.getTargets().add(new TargetPlayer());
        this.getSpellAbility().addMode(mode);
    }
View Full Code Here

        // Choose one — Creatures you control gain lifelink until end of turn;
        this.getSpellAbility().addEffect(new GainAbilityControlledEffect(LifelinkAbility.getInstance(), Duration.EndOfTurn, new FilterControlledCreaturePermanent("Creatures")));

        // or draw a card;
        Mode mode = new Mode();
        mode.getEffects().add(new DrawCardSourceControllerEffect(1));
        this.getSpellAbility().addMode(mode);

        // or put target attacking or blocking creature on top of its owner's library.
        mode = new Mode();
        mode.getTargets().add(new TargetAttackingOrBlockingCreature());
        mode.getEffects().add(new PutOnLibraryTargetEffect(true));
        this.getSpellAbility().addMode(mode);
    }
View Full Code Here

        // Choose one — Exile all cards from target player's graveyard;
        this.getSpellAbility().addEffect(new ExileGraveyardAllTargetPlayerEffect());
        this.getSpellAbility().addTarget(new TargetPlayer());

        // or destroy target artifact;
        Mode mode = new Mode();
        mode.getEffects().add(new DestroyTargetEffect());
        mode.getTargets().add(new TargetArtifactPermanent());
        this.getSpellAbility().addMode(mode);

        // or each creature deals 1 damage to its controller.
        mode = new Mode();
        mode.getEffects().add(new RakdosCharmDamageEffect());
        this.getSpellAbility().addMode(mode);
    }
View Full Code Here

        Ability ability = new EnchantAbility(auraTarget.getTargetName());
        this.addAbility(ability);

        // At the beginning of your upkeep, choose one - Destroy enchanted permanent; or you gain 2 life.
        ability = new BeginningOfUpkeepTriggeredAbility(new QuietDisrepairDestroyEffect(), TargetController.YOU, false);
        Mode mode = new Mode();
        mode.getEffects().add(new GainLifeEffect(2));
        ability.addMode(mode);
        this.addAbility(ability);
    }
View Full Code Here

        Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new ManaCostsImpl("{X}"));
        ability.addCost(new MarathWillOfTheWildRemoveCountersCost());
        ability.addTarget(new TargetCreaturePermanent());

        // or Marath deals X damage to target creature or player;
        Mode mode = new Mode();
        mode.getEffects().add(new DamageTargetEffect(new ManacostVariableValue()));
        mode.getTargets().add(new TargetCreatureOrPlayer());
        ability.addMode(mode);

        // or put an X/X green Elemental creature token onto the battlefield.
        mode = new Mode();
        mode.getEffects().add(new MarathWillOfTheWildCreateTokenEffect());
        ability.addMode(mode);

        // X can't be 0.
        for (VariableCost cost: ability.getManaCosts().getVariableCosts()) {
            if (cost instanceof VariableManaCost) {
View Full Code Here

        // Choose one - Return target permanent to its owner's hand;
        this.getSpellAbility().addEffect(new ReturnToHandTargetEffect());
        this.getSpellAbility().addTarget(new TargetPermanent());
        // or destroy target nonblack creature, and it can't be regenerated;
        Mode mode = new Mode();
        mode.getEffects().add(new DestroyTargetEffect(true));
        mode.getTargets().add(new TargetCreaturePermanent(filter));
        this.getSpellAbility().addMode(mode);
        // or destroy target artifact.
        mode = new Mode();
        mode.getEffects().add(new DestroyTargetEffect(true));
        Target target = new TargetArtifactPermanent();
        mode.getTargets().add(target);
        this.getSpellAbility().addMode(mode);

    }
View Full Code Here

        this.getSpellAbility().getModes().setMaxModes(2);
        // Incendiary Command deals 4 damage to target player;
        this.getSpellAbility().addEffect(new DamageTargetEffect(4));
        this.getSpellAbility().addTarget(new TargetPlayer());
        // or Incendiary Command deals 2 damage to each creature;
        Mode mode = new Mode();
        mode.getEffects().add(new DamageAllEffect(2, new FilterCreaturePermanent()));
        this.getSpellAbility().getModes().addMode(mode);
        // or destroy target nonbasic land;
        mode = new Mode();
        mode.getEffects().add(new DestroyTargetEffect());
        mode.getTargets().add(new TargetNonBasicLandPermanent());
        this.getSpellAbility().getModes().addMode(mode);
        // or each player discards all the cards in his or her hand, then draws that many cards.
        mode = new Mode();
        mode.getEffects().add(new IncendiaryCommandDrawEffect());
        this.getSpellAbility().getModes().addMode(mode);

    }
View Full Code Here

TOP

Related Classes of mage.abilities.Mode

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.