magarena/release/Magarena/scripts/Regal_Force.groovy

21 lines
722 B
Groovy

[
new MagicWhenComesIntoPlayTrigger() {
@Override
public MagicEvent executeTrigger(final MagicGame game, final MagicPermanent permanent, final MagicPayedCost payedCost) {
return new MagicEvent(
permanent,
this,
"PN draws a card for each green creature he or she controls."
);
}
@Override
public void executeEvent(final MagicGame game, final MagicEvent event) {
final MagicPlayer player = event.getPlayer();
game.doAction(new MagicDrawAction(
player,
player.getNrOfPermanents(MagicTargetFilter.TARGET_GREEN_CREATURE)
));
}
}
]