Menu

Submission for Morinfen

17

Config

name=Morinfen
image=http://mtgimage.com/card/morinfen.jpg
value=2.500
rarity=R
type=Legendary,Creature
subtype=Horror
cost={3}{B}{B}
pt=5/4
ability=Flying
timing=main
requires_groovy_code
oracle=Flying. Cumulative upkeep—Pay 1 life.

Script

[
    new MagicAtYourUpkeepTrigger() {
        @Override
        public MagicEvent executeTrigger(final MagicGame game,final MagicPermanent permanent,final MagicPlayer upkeepPlayer) {
            game.doAction(new MagicChangeCountersAction(
                permanent,
                MagicCounterType.Age,
                1
            ));
            return new MagicEvent(
                permanent,
                new MagicMayChoice("Pay cumulative upkeep?"),
                this,
                "PN may\$ lose 1 life for each Age counter on SN. " +
                " If he or she doesn't, sacrifice SN."
            );
        }
        @Override
        public void executeEvent(final MagicGame game, final MagicEvent event) {
            if (event.isYes()) {
                game.doAction(new MagicChangeLifeAction(event.getPlayer(),-event.getPermanent().getCounters(MagicCounterType.Age)));
            } else {
                game.doAction(new MagicSacrificeAction(event.getPermanent()));
            }
        }
    }
]
Pushed