13 lines
472 B
Groovy
13 lines
472 B
Groovy
[
|
|
new MagicWhenDamageIsDealtTrigger() {
|
|
@Override
|
|
public MagicEvent executeTrigger(final MagicGame game,final MagicPermanent permanent,final MagicDamage damage) {
|
|
final int amount = damage.getDealtAmount();
|
|
if (damage.getTarget() == permanent) {
|
|
game.doAction(new MagicMillLibraryAction(damage.getSource().getController(),amount));
|
|
}
|
|
return MagicEvent.NONE;
|
|
}
|
|
}
|
|
]
|