magarena/release/Magarena/scripts/Mind_Stone.groovy

34 lines
963 B
Groovy

[
new MagicPermanentActivation(
[
//Add one for the card itself
MagicConditionFactory.ManaCost("{2}")
],
new MagicActivationHints(MagicTiming.Draw),
"Draw"
) {
@Override
public Iterable<MagicEvent> getCostEvent(final MagicPermanent source) {
return [
new MagicTapEvent(source),
new MagicPayManaCostEvent(source,"{1}"),
new MagicSacrificeEvent(source)
];
}
@Override
public MagicEvent getPermanentEvent(final MagicPermanent source,final MagicPayedCost payedCost) {
return new MagicEvent(
source,
this,
"Draw a card."
);
}
@Override
public void executeEvent(final MagicGame game, final MagicEvent event) {
game.doAction(new MagicDrawAction(event.getPlayer()));
}
}
]