Menu

Submission for Well of Life

141

Config

name=Well of Life
image=http://mtgimage.com/card/well%20of%20life.jpg
value=2.500
rarity=U
type=Artifact
cost={4}
timing=main
requires_groovy_code
oracle=At the beginning of your end step, if you control no untapped lands, you gain 2 life.

Script

[
    new MagicAtEndOfTurnTrigger() {
        @Override
        public MagicEvent executeTrigger(final MagicGame game,final MagicPermanent permanent,final MagicPlayer endofturnPlayer) {
            return permanent.getController().controlsPermanent(MagicTargetFilterFactory.UNTAPPED_LAND) == false ?
                new MagicEvent(
                    permanent,
                    this,
                    "Gain 2 life."
                ):
                MagicEvent.NONE;
        }
        @Override
        public void executeEvent(final MagicGame game, final MagicEvent event) {
            if (event.getPlayer().controlsPermanent(MagicTargetFilterFactory.UNTAPPED_LAND) == false) {
                game.doAction(new MagicChangeLifeAction(event.getPlayer(),2));
            }
        }
    }
]
Pushed