2013-05-30 06:27:18 -07:00
|
|
|
[
|
2013-06-22 06:19:12 -07:00
|
|
|
new MagicWhenBlocksOrBecomesBlockedTrigger() {
|
2013-04-12 19:32:25 -07:00
|
|
|
@Override
|
|
|
|
public MagicEvent executeTrigger(final MagicGame game,final MagicPermanent permanent,final MagicPermanent blocker) {
|
2013-06-22 06:19:12 -07:00
|
|
|
final MagicPermanent target = permanent == blocker ? blocker.getBlockedCreature() : blocker;
|
|
|
|
return !target.hasColor(MagicColor.Black) ?
|
2013-04-12 19:32:25 -07:00
|
|
|
new MagicEvent(
|
|
|
|
permanent,
|
2013-06-22 06:19:12 -07:00
|
|
|
target,
|
2013-04-12 19:32:25 -07:00
|
|
|
this,
|
2013-05-30 06:27:18 -07:00
|
|
|
"Destroy RN at end of combat."
|
|
|
|
):
|
2013-04-12 19:32:25 -07:00
|
|
|
MagicEvent.NONE;
|
|
|
|
}
|
|
|
|
@Override
|
2013-05-30 06:27:18 -07:00
|
|
|
public void executeEvent(final MagicGame game, final MagicEvent event) {
|
2013-09-14 03:33:47 -07:00
|
|
|
event.processRefPermanent(game, {
|
|
|
|
final MagicPermanent permanent ->
|
|
|
|
game.doAction(new MagicAddTriggerAction(
|
|
|
|
permanent,
|
|
|
|
MagicAtEndOfCombatTrigger.Destroy
|
|
|
|
))
|
|
|
|
} as MagicPermanentAction);
|
2013-04-12 19:32:25 -07:00
|
|
|
}
|
2013-05-30 06:27:18 -07:00
|
|
|
}
|
|
|
|
]
|