magarena/release/Magarena/scripts/Gelectrode.groovy

23 lines
758 B
Groovy

[
new MagicWhenOtherSpellIsCastTrigger() {
@Override
public MagicEvent executeTrigger(
final MagicGame game,
final MagicPermanent permanent,
final MagicCardOnStack cardOnStack) {
return (permanent.isController(cardOnStack.getController()) &&
cardOnStack.getCardDefinition().isSpell()) ?
new MagicEvent(
permanent,
this,
"Untap SN."
):
MagicEvent.NONE;
}
@Override
public void executeEvent(final MagicGame game, final MagicEvent event) {
game.doAction(new MagicUntapAction(event.getPermanent()));
}
}
]