Menu

Submission for Resilient Wanderer

43

Config

name=Resilient Wanderer
image=http://mtgimage.com/card/resilient%20wanderer.jpg
value=2.500
rarity=U
type=Creature
subtype=Human,Nomad
cost={2}{W}{W}
pt=2/3
ability=First strike
timing=main
requires_groovy_code
oracle=First strike. Discard a card: Resilient Wanderer gains protection from the color of your choice until end of turn.

Script

[
    new MagicPermanentActivation(
        new MagicActivationHints(MagicTiming.Pump),
        "Protection"
    ) {
        @Override
        public Iterable<MagicEvent> getCostEvent(final MagicPermanent source) {
            return [new MagicDiscardEvent(source)
];
        }
        @Override
        public MagicEvent getPermanentEvent(final MagicPermanent source, final MagicPayedCost payedCost) {
            return new MagicEvent(
                source,
                MagicColorChoice.ALL_INSTANCE,
                this,
                "SN gains protection from the color\$ of your choice until end of turn."
            );
        }
        @Override
        public void executeEvent(final MagicGame game, final MagicEvent event) {
            game.doAction(new MagicGainAbilityAction(
                event.getPermanent(),
                event.getChosenColor().getProtectionAbility()
            ));
        }
    }
]
Pushed