2013-05-18 05:49:02 -07:00
|
|
|
[
|
|
|
|
new MagicWhenAttacksTrigger() {
|
2013-04-12 19:32:25 -07:00
|
|
|
@Override
|
|
|
|
public MagicEvent executeTrigger(final MagicGame game,final MagicPermanent permanent,final MagicPermanent creature) {
|
|
|
|
return (permanent == creature) ?
|
|
|
|
new MagicEvent(
|
|
|
|
permanent,
|
|
|
|
MagicTargetChoice.TARGET_CREATURE_YOU_CONTROL,
|
|
|
|
MagicFlyingTargetPicker.create(),
|
|
|
|
this,
|
2013-05-18 05:49:02 -07:00
|
|
|
"Target creature\$ you control gains flying until end of turn."
|
2013-04-12 19:32:25 -07:00
|
|
|
):
|
2013-06-23 18:29:26 -07:00
|
|
|
MagicEvent.NONE;
|
2013-04-12 19:32:25 -07:00
|
|
|
}
|
2013-06-23 18:29:26 -07:00
|
|
|
|
2013-04-12 19:32:25 -07:00
|
|
|
@Override
|
2013-05-18 05:49:02 -07:00
|
|
|
public void executeEvent(final MagicGame game, final MagicEvent event) {
|
2013-04-12 19:32:25 -07:00
|
|
|
event.processTargetPermanent(game,new MagicPermanentAction() {
|
|
|
|
public void doAction(final MagicPermanent creature) {
|
2013-07-06 23:57:29 -07:00
|
|
|
game.doAction(new MagicGainAbilityAction(creature,MagicAbility.Flying));
|
2013-04-12 19:32:25 -07:00
|
|
|
}
|
|
|
|
});
|
|
|
|
}
|
2013-05-18 05:49:02 -07:00
|
|
|
}
|
|
|
|
]
|