magarena/release/Magarena/scripts/Turn_to_Mist.groovy

23 lines
888 B
Groovy

[
new MagicSpellCardEvent() {
@Override
public MagicEvent getEvent(final MagicCardOnStack cardOnStack,final MagicPayedCost payedCost) {
return new MagicEvent(
cardOnStack,
MagicTargetChoice.TARGET_CREATURE,
MagicExileTargetPicker.create(),
this,
"Exile target creature\$. Return that card to the battlefield under its owner's control at the beginning of the next end step."
);
}
@Override
public void executeEvent(final MagicGame game, final MagicEvent event) {
event.processTargetPermanent(game,new MagicPermanentAction() {
public void doAction(final MagicPermanent creature) {
game.doAction(new MagicExileUntilEndOfTurnAction(creature));
}
});
}
}
]