magarena/release/Magarena/scripts/Sylvok_Lifestaff.groovy

22 lines
722 B
Groovy

[
new MagicWhenOtherPutIntoGraveyardFromPlayTrigger() {
@Override
public MagicEvent executeTrigger(final MagicGame game,final MagicPermanent permanent,final MagicPermanent died) {
return (permanent.getEquippedCreature()==died) ?
new MagicEvent(
permanent,
this,
"PN gains 3 life."
):
MagicEvent.NONE;
}
@Override
public void executeEvent(
final MagicGame game,
final MagicEvent event,
final Object[] choiceResults) {
game.doAction(new MagicChangeLifeAction(event.getPlayer(),3));
}
}
]