magarena/release/Magarena/scripts/Ulvenwald_Bear.groovy

31 lines
1.1 KiB
Groovy
Raw Normal View History

2013-05-18 20:13:42 -07:00
[
new MagicWhenComesIntoPlayTrigger() {
@Override
public MagicEvent executeTrigger(final MagicGame game,final MagicPermanent permanent, final MagicPlayer player) {
return (game.getCreatureDiedThisTurn()) ?
new MagicEvent(
permanent,
MagicTargetChoice.POS_TARGET_CREATURE,
MagicPumpTargetPicker.create(),
this,
"PN puts two +1/+1 counters on target creature\$."
):
MagicEvent.NONE;
}
@Override
public void executeEvent(final MagicGame game, final MagicEvent event) {
event.processTargetPermanent(game,new MagicPermanentAction() {
public void doAction(final MagicPermanent creature) {
game.doAction(new MagicChangeCountersAction(
creature,
MagicCounterType.PlusOne,
2,
true
));
}
});
}
}
]