magarena/release/Magarena/scripts/Goblin_Burrows.groovy

40 lines
1.3 KiB
Groovy

[
new MagicPermanentActivation(
[
MagicConditionFactory.ManaCost("{2}{R}"), //add ONE for the card itself
MagicCondition.CAN_TAP_CONDITION
],
new MagicActivationHints(MagicTiming.Pump),
"Pump"
) {
@Override
public MagicEvent[] getCostEvent(final MagicPermanent source) {
return [
new MagicTapEvent(source),
new MagicPayManaCostEvent(source,"{1}{R}")
];
}
@Override
public MagicEvent getPermanentEvent(final MagicPermanent source,final MagicPayedCost payedCost) {
return new MagicEvent(
source,
MagicTargetChoice.POS_TARGET_GOBLIN_CREATURE,
MagicPumpTargetPicker.create(),
this,
"Target Goblin creature\$ gets +2/+0 until end of turn."
);
}
@Override
public void executeEvent(final MagicGame game, final MagicEvent event) {
event.processTargetPermanent(game,new MagicPermanentAction() {
public void doAction(final MagicPermanent creature) {
game.doAction(new MagicChangeTurnPTAction(creature,2,0));
}
});
}
}
]