magarena/release/Magarena/scripts/Faceless_Butcher.groovy

27 lines
1.1 KiB
Groovy

[
new MagicWhenComesIntoPlayTrigger() {
@Override
public MagicEvent executeTrigger(final MagicGame game,final MagicPermanent permanent, final MagicPlayer player) {
final MagicTargetFilter<MagicPermanent> targetFilter = new MagicTargetFilter.MagicOtherPermanentTargetFilter(
MagicTargetFilter.TARGET_CREATURE,permanent);
final MagicTargetChoice targetChoice = new MagicTargetChoice(
targetFilter,true,MagicTargetHint.None,"another creature to exile");
return new MagicEvent(
permanent,
targetChoice,
MagicExileTargetPicker.create(),
this,
"Exile another creature\$."
);
}
@Override
public void executeEvent(final MagicGame game, final MagicEvent event) {
event.processTargetPermanent(game,new MagicPermanentAction() {
public void doAction(final MagicPermanent creature) {
game.doAction(new MagicExileUntilThisLeavesPlayAction(event.getPermanent(),creature));
}
});
}
}
]