24 lines
930 B
Groovy
24 lines
930 B
Groovy
[
|
|
new MagicWhenOtherPutIntoGraveyardFromPlayTrigger() {
|
|
@Override
|
|
public MagicEvent executeTrigger(final MagicGame game,final MagicPermanent permanent,final MagicPermanent otherPermanent) {
|
|
return otherPermanent.isCreature() ?
|
|
new MagicEvent(
|
|
permanent,
|
|
MagicTargetChoice.NEG_TARGET_PLAYER,
|
|
this,
|
|
"Target player\$ puts the top card of his or her library into his or her graveyard."
|
|
):
|
|
MagicEvent.NONE;
|
|
}
|
|
@Override
|
|
public void executeEvent(final MagicGame game, final MagicEvent event) {
|
|
event.processTargetPlayer(game,new MagicPlayerAction() {
|
|
public void doAction(final MagicPlayer player) {
|
|
game.doAction(new MagicMillLibraryAction(player,1));
|
|
}
|
|
});
|
|
}
|
|
}
|
|
]
|