13 lines
447 B
Groovy
13 lines
447 B
Groovy
[
|
|
new MagicIfDamageWouldBeDealtTrigger(2) {
|
|
@Override
|
|
public MagicEvent executeTrigger(final MagicGame game,final MagicPermanent permanent,final MagicDamage damage) {
|
|
if (permanent.isController(damage.getTarget())) {
|
|
// Replacement effect. Generates no event or action.
|
|
damage.setTarget(permanent);
|
|
}
|
|
return MagicEvent.NONE;
|
|
}
|
|
}
|
|
]
|