Menu

Submission for Power Taint

90

Config

name=Power Taint
image=http://mtgimage.com/card/power%20taint.jpg
value=2.500
rarity=C
type=Enchantment
subtype=Aura
cost={1}{U}
ability=Cycling {2}
timing=aura
enchant=default,neg enchantment
oracle=Enchant enchantment. At the beginning of the upkeep of enchanted enchantment's controller, that player loses 2 life unless he or she pays {2}. Cycling {2}

Script

[
    new MagicAtUpkeepTrigger() {
        @Override
        public MagicEvent executeTrigger(final MagicGame game, final MagicPermanent permanent, final MagicPlayer upkeepPlayer) {
            final MagicPermanent enchantedEnchantment = permanent.getEnchantedPermanent();
            return (enchantedEnchantment.isEnchantment() && enchantedEnchantment.isController(upkeepPlayer)) ?
                new MagicEvent(
                    permanent,
                    upkeepPlayer,
                    new MagicMayChoice(
                        "Pay {2}?",
                        new MagicPayManaCostChoice(MagicManaCost.create("{2}"))
                    ),
                    this,
                    "PN may\$ pay {2}\$. If PN doesn't, PN loses 2 life."
                ) :
                MagicEvent.NONE;
        }
        @Override
        public void executeEvent(final MagicGame game, final MagicEvent event) {
            if (event.isNo()) {
                game.doAction(new MagicChangeLifeAction(event.getPlayer(),-2));
            }
        }
    }
]
Pushed