Menu

Submission for Insolence

63

Comment

Adapted from Psychic Venom

Config

name=Insolence
image=http://mtgimage.com/card/insolence.jpg
value=2.500
rarity=C
type=Enchantment
subtype=Aura
cost={2}{R}
enchant=default,neg creature
timing=enchantment
requires_groovy_code
oracle=Enchant creature. Whenever enchanted creature becomes tapped, Insolence deals 2 damage to that creature's controller.

Script

[
    new MagicWhenBecomesTappedTrigger() {
        @Override
        public MagicEvent executeTrigger(final MagicGame game, final MagicPermanent permanent, final MagicPermanent tapped) {
            final MagicPermanent enchantedCreature = permanent.getEnchantedPermanent();
            return (enchantedCreature.isCreature() && enchantedCreature==tapped) ?
                new MagicEvent(
                    permanent,
                    tapped.getController(),
                    this,
                    "SN deals 2 damage to PN."
                ) :
                MagicEvent.NONE;
        }
        @Override
        public void executeEvent(final MagicGame game,final MagicEvent event) {
            final MagicDamage damage=new MagicDamage(event.getSource(),event.getPlayer(),2);
            game.doAction(new MagicDealDamageAction(damage));
        }
    }
]
Pushed