Menu

Submission for Thornscape Master

216

Config

name=Stormscape Master
image=http://magiccards.info/scans/en/in/76.jpg
value=2.500
rarity=R
type=Creature
subtype=Human,Wizard
cost={2}{U}{U}
pt=2/2
ability={B}{B}, {T}: Target player loses 2 life and you gain 2 life.
timing=main
requires_groovy_code
oracle={W}{W}, {T}: Target creature gains protection from the color of your choice until end of turn. {B}{B}, {T}: Target player loses 2 life and you gain 2 life.

Script

def action = {
    final MagicGame game, final MagicEvent event ->
    game.doAction(new MagicGainAbilityAction(
        event.getRefPermanent(),
        event.getChosenColor().getProtectionAbility()
    ));
}

[
    new MagicPermanentActivation(
        new MagicActivationHints(MagicTiming.Pump),
        "Protection"
    ) {
        @Override
        public Iterable<MagicEvent> getCostEvent(final MagicPermanent source) {
            return [
                    new MagicPayManaCostEvent(source,"{W}{W}"),
                    new MagicTapEvent(source)
                ];
        }
        @Override
        public MagicEvent getPermanentEvent(final MagicPermanent source,final MagicPayedCost payedCost) {
            return new MagicEvent(
                source,
                MagicTargetChoice.POS_TARGET_CREATURE,
                this,
                "Target creature\$ gains protection from the color of your choice until end of turn."
            );
        }
        @Override
        public void executeEvent(final MagicGame game, final MagicEvent event) {
            event.processTargetPermanent(game, {
                game.addEvent(new MagicEvent(
                    event.getSource(),
                    event.getPlayer(),
                    MagicColorChoice.ALL_INSTANCE,
                    it,
                    action,
                    "Chosen color\$."
                ));
            });
        }
    }
]
Pushed