magarena/release/Magarena/scripts/Experiment_One.groovy

32 lines
991 B
Groovy
Raw Normal View History

2013-03-11 22:47:41 -07:00
[
new MagicPermanentActivation(
[
MagicConditionFactory.PlusOneCounterAtLeast(2),
MagicCondition.CAN_REGENERATE_CONDITION,
],
new MagicActivationHints(MagicTiming.Pump),
"Regen") {
@Override
public MagicEvent[] getCostEvent(final MagicPermanent source) {
return [
new MagicRemoveCounterEvent(source,MagicCounterType.PlusOne,2)
];
}
@Override
public MagicEvent getPermanentEvent(final MagicPermanent source,final MagicPayedCost payedCost) {
return new MagicEvent(
source,
this,
"Regenerate SN."
);
}
@Override
public void executeEvent(
final MagicGame game,
final MagicEvent event,
final Object[] choiceResults) {
game.doAction(new MagicRegenerateAction(event.getPermanent()));
}
}
]