magarena/release/Magarena/scripts/Healer_of_the_Pride.groovy

21 lines
782 B
Groovy

[
new MagicWhenOtherComesIntoPlayTrigger() {
@Override
public MagicEvent executeTrigger(final MagicGame game,final MagicPermanent permanent,final MagicPermanent otherPermanent) {
return (otherPermanent != permanent &&
otherPermanent.isCreature() &&
otherPermanent.isFriend(permanent)) ?
new MagicEvent(
permanent,
this,
"PN gains 2 life."
):
MagicEvent.NONE;
}
@Override
public void executeEvent(final MagicGame game, final MagicEvent event) {
game.doAction(new MagicChangeLifeAction(event.getPlayer(),2));
}
}
]