Package mage.abilities.common

Examples of mage.abilities.common.SimpleActivatedAbility.addCost()


        this.color.setGreen(true);
        this.power = new MageInt(0);
        this.toughness = new MageInt(0);
        this.addAbility(new EntersBattlefieldTriggeredAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance(1))));
        Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new AddCountersTargetEffect(CounterType.P1P1.createInstance(1)), new GenericManaCost(2));
        ability.addCost(new RemoveCountersSourceCost(CounterType.P1P1.createInstance(1)));
        ability.addTarget(new TargetCreaturePermanent());
        this.addAbility(ability);
    }

    public SpikeDrone(final SpikeDrone card) {
View Full Code Here


        super(ownerId, 336, "Ebony Horse", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{3}");
        this.expansionSetCode = "4ED";

        // {2}, {tap}: Untap target attacking creature you control. Prevent all combat damage that would be dealt to and dealt by that creature this turn.
        Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new UntapTargetEffect(), new GenericManaCost(2));
        ability.addCost(new TapSourceCost());
        ability.addEffect(new PreventCombatDamageToSourceEffect(Duration.EndOfTurn));
        ability.addEffect(new PreventCombatDamageBySourceEffect(Duration.EndOfTurn));
        Target target = new TargetCreaturePermanent(filter);
        ability.addTarget(target);
        this.addAbility(ability);
View Full Code Here

        this.subtype.add("Sliver");
        this.color.setBlue(true);
        this.power = new MageInt(2);
        this.toughness = new MageInt(2);
        Ability gainedAbility = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DrawCardSourceControllerEffect(1), new GenericManaCost(2));
        gainedAbility.addCost(new SacrificeSourceCost());
        this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAllEffect(gainedAbility, Duration.WhileOnBattlefield, filter, false)));
    }

    public MnemonicSliver(final MnemonicSliver card) {
        super(card);
View Full Code Here

        super(ownerId, 294, "Puppet Strings", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT}, "{3}");
        this.expansionSetCode = "TMP";

        // {2}, {tap}: You may tap or untap target creature.
        Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new MayTapOrUntapTargetEffect(), new GenericManaCost(2));
        ability.addCost(new TapSourceCost());
        ability.addTarget(new TargetCreaturePermanent());
        this.addAbility(ability);
    }

    public PuppetStrings(final PuppetStrings card) {
View Full Code Here

        this.addAbility(new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, effect, TargetController.YOU, false, false));
        // {tap}, Remove an arrowhead counter from Serrated Arrows: Put a -1/-1 counter on target creature.
        Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD,
                new AddCountersTargetEffect(CounterType.M1M1.createInstance()),
                new TapSourceCost());
        ability.addCost(new RemoveCountersSourceCost(CounterType.ARROWHEAD.createInstance()));
        ability.addTarget(new TargetCreaturePermanent());
        this.addAbility(ability);
    }

    public SerratedArrows(final SerratedArrows card) {
View Full Code Here

        this.toughness = new MageInt(1);

        // {2}{B}, Sacrifice Corpse Hauler: Return another target creature card from your graveyard to your hand.
        Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnFromGraveyardToHandTargetEffect(), new ManaCostsImpl("{2}{B}"));
        ability.addTarget(new TargetCardInYourGraveyard(filter));
        ability.addCost(new SacrificeSourceCost());
        this.addAbility(ability);
    }

    public CorpseHauler(final CorpseHauler card) {
        super(card);
View Full Code Here

    public Tanglebloom(UUID ownerId) {
        super(ownerId, 258, "Tanglebloom", Rarity.COMMON, new CardType[]{CardType.ARTIFACT}, "{1}");
        this.expansionSetCode = "MRD";
        Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainLifeEffect(1), new GenericManaCost(1));
        ability.addCost(new TapSourceCost());
        this.addAbility(ability);
        // {1}, {tap}: You gain 1 life.
    }

    public Tanglebloom(final Tanglebloom card) {
View Full Code Here

        super(ownerId, 224, "Strionic Resonator", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{2}");
        this.expansionSetCode = "M14";

        // {2}, {T}: Copy target triggered ability you control. You may choose new targets for the copy.
        Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new StrionicResonatorEffect(), new ManaCostsImpl("{2}"));
        ability.addCost(new TapSourceCost());
        ability.addTarget(new TargetTriggeredAbility());
        this.addAbility(ability);
    }

    public StrionicResonator(final StrionicResonator card) {
View Full Code Here

        // A deck can have any number of cards named Shadowborn Apostle.
        this.addInfo("rule", "A deck can have any number of cards named Shadowborn Apostle.");
        // {B}, Sacrifice six creatures named Shadowborn Apostle: Search your library for a Demon creature and put it onto the battlefield. Then shuffle your library.
        Effect effect = new SearchLibraryPutInPlayEffect(new TargetCardInLibrary(filter), false, true);
        Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new ManaCostsImpl("{B}"));
        ability.addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent(6,6,filterApostle, false)));
        this.addAbility(ability);
    }

    public ShadowbornApostle(final ShadowbornApostle card) {
        super(card);
View Full Code Here

        this.expansionSetCode = "TMP";

        // {3}, {tap}: Name a card. Reveal a card at random from your hand. If it's the named card, Cursed Scroll deals 2 damage to target creature or player.
        Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new NameACardEffect(NameACardEffect.TypeOfName.ALL), new ManaCostsImpl("{3}"));
        ability.addEffect(new CursedScrollEffect());
        ability.addCost(new TapSourceCost());
        ability.addTarget(new TargetCreatureOrPlayer());
        this.addAbility(ability);
    }

    public CursedScroll(final CursedScroll card) {
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.