Menu

Submission for Sphere of Truth

52

Config

name=Sphere of Truth
image=http://mtgimage.com/card/sphere%20of%20truth.jpg
value=2.500
rarity=U
type=Enchantment
cost={3}{W}
timing=enchantment
requires_groovy_code
oracle=If a white source would deal damage to you, prevent 2 of that damage.

Script

[
    new MagicIfDamageWouldBeDealtTrigger(MagicTrigger.PREVENT_DAMAGE) {
        @Override
        public MagicEvent executeTrigger(final MagicGame game,final MagicPermanent permanent,final MagicDamage damage) {
            if (permanent.isController(damage.getTarget()) && damage.getSource().hasColor(MagicColor.White)) {
                // Prevention effect.
                damage.prevent(2);
            }
            return MagicEvent.NONE;
        }
    }
]
Pushed