forked from External/mage
52 lines
1.9 KiB
Java
52 lines
1.9 KiB
Java
|
|
package mage.cards.p;
|
|
|
|
import java.util.UUID;
|
|
import mage.abilities.Ability;
|
|
import mage.abilities.common.BecomesTappedAttachedTriggeredAbility;
|
|
import mage.abilities.common.SimpleActivatedAbility;
|
|
import mage.abilities.costs.mana.ManaCostsImpl;
|
|
import mage.abilities.effects.common.AttachEffect;
|
|
import mage.abilities.effects.common.DestroyAttachedToEffect;
|
|
import mage.abilities.effects.common.LoseLifeControllerAttachedEffect;
|
|
import mage.abilities.keyword.EnchantAbility;
|
|
import mage.cards.CardImpl;
|
|
import mage.cards.CardSetInfo;
|
|
import mage.constants.CardType;
|
|
import mage.constants.SubType;
|
|
import mage.constants.Outcome;
|
|
import mage.constants.Zone;
|
|
import mage.target.TargetPermanent;
|
|
import mage.target.common.TargetLandPermanent;
|
|
|
|
/**
|
|
*
|
|
* @author LoneFox
|
|
*/
|
|
public final class PoolingVenom extends CardImpl {
|
|
|
|
public PoolingVenom(UUID ownerId, CardSetInfo setInfo) {
|
|
super(ownerId,setInfo,new CardType[]{CardType.ENCHANTMENT},"{1}{B}");
|
|
this.subtype.add(SubType.AURA);
|
|
|
|
// Enchant land
|
|
TargetPermanent auraTarget = new TargetLandPermanent();
|
|
this.getSpellAbility().addTarget(auraTarget);
|
|
this.getSpellAbility().addEffect(new AttachEffect(Outcome.Detriment));
|
|
Ability ability = new EnchantAbility(auraTarget.getTargetName());
|
|
this.addAbility(ability);
|
|
// Whenever enchanted land becomes tapped, its controller loses 2 life.
|
|
this.addAbility(new BecomesTappedAttachedTriggeredAbility(new LoseLifeControllerAttachedEffect(2), "enchanted land"));
|
|
// {3}{B}: Destroy enchanted land.
|
|
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new DestroyAttachedToEffect("enchanted land"), new ManaCostsImpl("{3}{B}")));
|
|
}
|
|
|
|
private PoolingVenom(final PoolingVenom card) {
|
|
super(card);
|
|
}
|
|
|
|
@Override
|
|
public PoolingVenom copy() {
|
|
return new PoolingVenom(this);
|
|
}
|
|
}
|