magarena/release/Magarena/scripts/Drana__Kalastria_Bloodchief...

38 lines
1.3 KiB
Groovy
Raw Normal View History

2013-05-27 07:55:41 -07:00
[
new MagicPermanentActivation(
new MagicActivationHints(MagicTiming.Removal),
"Pump"
) {
@Override
public MagicEvent[] getCostEvent(final MagicPermanent source) {
return [new MagicPayManaCostEvent(source,"{X}{B}{B}")];
}
@Override
public MagicEvent getPermanentEvent(final MagicPermanent source,final MagicPayedCost payedCost) {
2013-05-27 08:00:58 -07:00
final int amount = payedCost.getX();
2013-05-27 07:55:41 -07:00
return new MagicEvent(
source,
MagicTargetChoice.TARGET_CREATURE,
new MagicWeakenTargetPicker(0,amount),
2013-05-27 08:00:58 -07:00
amount,
2013-05-27 07:55:41 -07:00
this,
2013-05-27 08:00:58 -07:00
"Target creature\$ gets -0/-RN until end of turn and " +
2013-05-27 07:55:41 -07:00
"SN gets +RN/+0 until end of turn."
);
}
@Override
public void executeEvent(final MagicGame game, final MagicEvent event) {
final int amount=event.getRefInt();
event.processTargetPermanent(game,new MagicPermanentAction() {
public void doAction(final MagicPermanent creature) {
game.doAction(new MagicChangeTurnPTAction(creature,0,-amount));
game.doAction(new MagicChangeTurnPTAction(event.getPermanent(),amount,0));
}
});
}
}
]