magarena/release/Magarena/scripts/Sarkhan_Vol.groovy

70 lines
2.6 KiB
Groovy

[
new MagicPlaneswalkerActivation(1) {
@Override
public MagicEvent getPermanentEvent(final MagicPermanent source,final MagicPayedCost payedCost) {
return new MagicEvent(
source,
this,
"Creatures you control get +1/+1 and gain haste until end of turn."
);
}
@Override
public void executeEvent(
final MagicGame game,
final MagicEvent event) {
final Collection<MagicPermanent> targets = game.filterPermanents(
event.getPlayer(),
MagicTargetFilter.TARGET_CREATURE_YOU_CONTROL
);
for (final MagicPermanent creature : targets) {
game.doAction(new MagicChangeTurnPTAction(creature, 1, 1));
game.doAction(new MagicSetAbilityAction(creature, MagicAbility.Haste));
}
}
},
new MagicPlaneswalkerActivation(-2) {
@Override
public MagicEvent getPermanentEvent(final MagicPermanent source,final MagicPayedCost payedCost) {
return new MagicEvent(
source,
MagicTargetChoice.NEG_TARGET_CREATURE,
MagicExileTargetPicker.create(),
this,
"Gain control of target creature\$ until end of turn. Untap that creature. It gains haste until end of turn."
);
}
@Override
public void executeEvent(
final MagicGame game,
final MagicEvent event) {
event.processTargetPermanent(game,new MagicPermanentAction() {
public void doAction(final MagicPermanent perm) {
game.doAction(new MagicGainControlAction(event.getPlayer(),perm,MagicStatic.UntilEOT));
game.doAction(new MagicUntapAction(perm));
game.doAction(new MagicSetAbilityAction(perm,MagicAbility.Haste));
}
});
}
},
new MagicPlaneswalkerActivation(-6) {
@Override
public MagicEvent getPermanentEvent(final MagicPermanent source,final MagicPayedCost payedCost) {
return new MagicEvent(
source,
this,
"Put five 4/4 red Dragon creature tokens with flying onto the battlefield."
);
}
@Override
public void executeEvent(
final MagicGame game,
final MagicEvent event) {
game.doAction(new MagicPlayTokensAction(
event.getPlayer(),
TokenCardDefinitions.get("Dragon4"),
5
));
}
}
]