From 3e851b08f45c68a1cbadbb306b12a6cbe22fa42c Mon Sep 17 00:00:00 2001 From: marcins78 Date: Mon, 7 Jan 2013 16:48:22 +0000 Subject: [PATCH] "Push Back the Darkness" --- .../lotro/cards/set20/elven/Card20_102.java | 46 +++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set20/elven/Card20_102.java diff --git a/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set20/elven/Card20_102.java b/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set20/elven/Card20_102.java new file mode 100644 index 000000000..72b541704 --- /dev/null +++ b/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set20/elven/Card20_102.java @@ -0,0 +1,46 @@ +package com.gempukku.lotro.cards.set20.elven; + +import com.gempukku.lotro.cards.AbstractEvent; +import com.gempukku.lotro.cards.PlayConditions; +import com.gempukku.lotro.cards.actions.PlayEventAction; +import com.gempukku.lotro.cards.effects.AddUntilEndOfPhaseModifierEffect; +import com.gempukku.lotro.cards.effects.choose.ChooseAndExertCharactersEffect; +import com.gempukku.lotro.cards.modifiers.ArcheryTotalModifier; +import com.gempukku.lotro.cards.modifiers.evaluator.CountActiveEvaluator; +import com.gempukku.lotro.common.Culture; +import com.gempukku.lotro.common.Keyword; +import com.gempukku.lotro.common.Phase; +import com.gempukku.lotro.common.Side; +import com.gempukku.lotro.filters.Filters; +import com.gempukku.lotro.game.PhysicalCard; +import com.gempukku.lotro.game.state.LotroGame; + +/** + * 1 + * Push Back the Darkness + * Elven Event • Archery + * Exert an [Elven] archer to make the fellowship archery total +1 for each site your opponent controls. + */ +public class Card20_102 extends AbstractEvent { + public Card20_102() { + super(Side.FREE_PEOPLE, 1, Culture.ELVEN, "Push Back the Darkness", Phase.ARCHERY); + } + + @Override + public boolean checkPlayRequirements(String playerId, LotroGame game, PhysicalCard self, int withTwilightRemoved, int twilightModifier, boolean ignoreRoamingPenalty, boolean ignoreCheckingDeadPile) { + return super.checkPlayRequirements(playerId, game, self, withTwilightRemoved, twilightModifier, ignoreRoamingPenalty, ignoreCheckingDeadPile) + && PlayConditions.canExert(self, game, Culture.ELVEN, Keyword.ARCHER); + } + + @Override + public PlayEventAction getPlayCardAction(String playerId, LotroGame game, PhysicalCard self, int twilightModifier, boolean ignoreRoamingPenalty) { + PlayEventAction action = new PlayEventAction(self); + action.appendCost( + new ChooseAndExertCharactersEffect(action, playerId, 1, 1, Culture.ELVEN, Keyword.ARCHER)); + action.appendEffect( + new AddUntilEndOfPhaseModifierEffect( + new ArcheryTotalModifier(self, Side.FREE_PEOPLE, null, + new CountActiveEvaluator(Filters.siteControlledByShadowPlayer(playerId))), Phase.ARCHERY)); + return action; + } +}