Menu

Submission for Nightmarish End

76

Config

name=Nightmarish End
image=http://mtgimage.com/card/nightmarish%20end.jpg
value=2.500
rarity=U
type=Instant
cost={2}{B}
timing=removal
requires_groovy_code
oracle=Target creature gets -X/-X until end of turn, where X is the number of cards in your hand.

Script

[
    new MagicSpellCardEvent() {
        @Override
        public MagicEvent getEvent(final MagicCardOnStack cardOnStack,final MagicPayedCost payedCost) {
            return new MagicEvent(
                cardOnStack,
			MagicTargetChoice.NEG_TARGET_CREATURE,
                this,
                "Target creature\$ gets -X/-X until end of turn, where X is the number of cards in your hand."
            );
        }
        @Override
        public void executeEvent(final MagicGame game, final MagicEvent event) {
		event.processTargetPermanent(game, {
		final MagicPlayer player = event.getPlayer();
		final int amount = player.getHandSize();
            game.doAction(new MagicChangeTurnPTAction(it,-amount,-amount));
	});
        }
    }
]
Pushed