2013-03-05 22:03:51 -08:00
|
|
|
[
|
|
|
|
new MagicWhenOtherPutIntoGraveyardFromPlayTrigger() {
|
|
|
|
@Override
|
|
|
|
public MagicEvent executeTrigger(final MagicGame game,final MagicPermanent permanent,final MagicPermanent died) {
|
|
|
|
return (permanent == died && permanent.getOwner() == permanent.getController()) ?
|
|
|
|
new MagicEvent(
|
|
|
|
permanent,
|
|
|
|
new MagicSimpleMayChoice(MagicSimpleMayChoice.DRAW_CARDS, 0, MagicSimpleMayChoice.DEFAULT_NONE),
|
|
|
|
this,
|
|
|
|
"PN may\$ return SN to his/her hand."
|
|
|
|
):
|
|
|
|
MagicEvent.NONE;
|
|
|
|
}
|
|
|
|
@Override
|
|
|
|
public void executeEvent(
|
|
|
|
final MagicGame game,
|
2013-03-22 22:00:53 -07:00
|
|
|
final MagicEvent event) {
|
2013-03-11 22:08:12 -07:00
|
|
|
final MagicCard card = event.getPermanent().getCard()
|
2013-03-22 19:26:50 -07:00
|
|
|
if (event.isYes() && event.getPlayer().getGraveyard().contains(card)) {
|
2013-03-05 22:03:51 -08:00
|
|
|
game.doAction(new MagicRemoveCardAction(card,MagicLocationType.Graveyard));
|
|
|
|
game.doAction(new MagicMoveCardAction(card,MagicLocationType.Graveyard,MagicLocationType.OwnersHand));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
]
|