magarena/incomplete/Lay_Bare.groovy

22 lines
812 B
Groovy

[
new MagicSpellCardEvent() {
@Override
public MagicEvent getEvent(final MagicCardOnStack cardOnStack,final MagicPayedCost payedCost) {
return new MagicEvent(
cardOnStack,
MagicTargetChoice.NEG_TARGET_SPELL,
this,
"Counter target spell\$. Look at its controller's hand."
);
}
@Override
public void executeEvent(final MagicGame game, final MagicEvent event) {
event.processTargetCardOnStack(game, {
final MagicCardOnStack targetSpell ->
game.doAction(new MagicCounterItemOnStackAction(targetSpell));
game.doAction(new MagicRevealAction(targetSpell.getCard().getController().getHand()));
});
}
}
]