Menu

Submission for Ghoul's Feast

67

Config

name=Ghoul's Feast
image=http://mtgimage.com/card/ghoul%27s%20feast.jpg
value=2.500
rarity=U
type=Instant
cost={1}{B}
timing=pump
requires_groovy_code
oracle=Target creature gets +X/+0 until end of turn, where X is the number of creature cards in your graveyard.

Script

[
    new MagicSpellCardEvent() {
        @Override
        public MagicEvent getEvent(final MagicCardOnStack cardOnStack,final MagicPayedCost payedCost) {
            return new MagicEvent(
                cardOnStack,
                MagicTargetChoice.POS_TARGET_CREATURE,
                this,
                "Target creature \$ gets +X/+0 until end of turn, where X is the number of creature cards in PN's graveyard."
            );
        }
        @Override
        public void executeEvent(final MagicGame game, final MagicEvent event) {
            final int amount = game.filterCards(event.getPermanent().getController(),MagicTargetFilterFactory.CREATURE_CARD_FROM_GRAVEYARD).size();
            event.processTargetPermanent(game, {
                game.doAction(new MagicChangeTurnPTAction(
                    it,
                    amount,
                    0
                    ));
            });
        }
    }
]
Pushed