Package mage.abilities.effects.common

Examples of mage.abilities.effects.common.LoseLifeTargetEffect


   
    @Override
    public boolean checkTrigger(GameEvent event, Game game) {
        if (event.getType() == EventType.GAINED_LIFE) {
            this.getEffects().clear();
            Effect effect = new LoseLifeTargetEffect(2 * event.getAmount());
            effect.setTargetPointer(new FixedTarget(event.getPlayerId()));
            this.addEffect(effect);
            return true;
        }
        return false;
    }
View Full Code Here


        this.color.setBlack(true);
        this.power = new MageInt(1);
        this.toughness = new MageInt(1);

        // Whenever a player casts a black spell, you may pay {1}. If you do, target player loses 1 life.
        Ability ability = new SpellCastAllTriggeredAbility(new DoIfCostPaid(new LoseLifeTargetEffect(1), new ManaCostsImpl("{1}")), filter, false);
        ability.addTarget(new TargetPlayer());
        this.addAbility(ability);
       
    }
View Full Code Here

        this.color.setBlack(true);
        this.power = new MageInt(2);
        this.toughness = new MageInt(2);
        Ability ability = new EntersBattlefieldTriggeredAbility(new GainLifeEffect(2));
        ability.addTarget(new TargetOpponent());
        ability.addEffect(new LoseLifeTargetEffect(2));
        this.addAbility(ability);
    }
View Full Code Here

}

class QuestForTheNihilStoneTriggeredAbility2 extends TriggeredAbilityImpl {

    public QuestForTheNihilStoneTriggeredAbility2() {
        super(Zone.BATTLEFIELD, new LoseLifeTargetEffect(5), true);
    }
View Full Code Here

}

class RoilingHorrorTriggeredAbility extends TriggeredAbilityImpl {

    public RoilingHorrorTriggeredAbility() {
        super(Zone.EXILED, new LoseLifeTargetEffect(1), false);
        this.addTarget(new TargetPlayer());
        Effect effect = new GainLifeEffect(1);
        effect.setText("and you gain 1 life");
        this.addEffect(effect);
    }
View Full Code Here

        this.getSpellAbility().addEffect(new AttachEffect(Outcome.AddAbility));
        Ability ability = new EnchantAbility(auraTarget.getTargetName());
        this.addAbility(ability);
       
        // Enchanted land has "{tap}: Target player loses 3 life."
        Ability tarAbility = new SimpleActivatedAbility(Zone.BATTLEFIELD, new LoseLifeTargetEffect(3), new TapSourceCost());
        tarAbility.addTarget(new TargetPlayer());
        this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(tarAbility, AttachmentType.AURA,
                Duration.WhileOnBattlefield,"Enchanted land has \"{t}: Target player loses 3 life.\"")));
       
    }
View Full Code Here

        this.color.setRed(true);
        this.power = new MageInt(1);
        this.toughness = new MageInt(1);

        // {B}, {tap}: Target player loses 1 life.
        Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new LoseLifeTargetEffect(1), new ColoredManaCost(ColoredManaSymbol.B));
        ability.addCost(new TapSourceCost());
        ability.addTarget(new TargetPlayer());
        this.addAbility(ability);
        // {G}, {tap}: Target creature gets +1/+1 until end of turn.
        ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(1, 1, Duration.EndOfTurn), new ColoredManaCost(ColoredManaSymbol.G));
View Full Code Here

        this.expansionSetCode = "CHK";
        this.subtype.add("Spirit");
        this.color.setBlack(true);
        this.power = new MageInt(2);
        this.toughness = new MageInt(2);
        Ability ability = new SpellCastControllerTriggeredAbility(new LoseLifeTargetEffect(1), filter, false);
        ability.addEffect(new GainLifeEffect(1));
        ability.addTarget(new TargetOpponent());
        this.addAbility(ability);
        this.addAbility(new SoulshiftAbility(2));
    }
View Full Code Here

        this.color.setBlack(true);
        this.power = new MageInt(1);
        this.toughness = new MageInt(1);

        // {U}{B}, {tap}: Target player loses 1 life and reveals his or her hand.
        Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new LoseLifeTargetEffect(1), new ManaCostsImpl("{U}{B}"));
        ability.addCost(new TapSourceCost());
       
        Effect revealEffect = new RevealHandTargetEffect(TargetController.ANY);
        revealEffect.setText("and reveals his or her hand");
        ability.addEffect(revealEffect);
View Full Code Here

        this.color.setBlack(true);
        this.power = new MageInt(1);
        this.toughness = new MageInt(1);

        // When Infectious Host dies, target player loses 2 life.
        Ability ability = new DiesTriggeredAbility(new LoseLifeTargetEffect(2), false);
        ability.addTarget(new TargetPlayer());
        this.addAbility(ability);
    }
View Full Code Here

TOP

Related Classes of mage.abilities.effects.common.LoseLifeTargetEffect

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.