From a04672af05577f75574f26773abf118d0367fede Mon Sep 17 00:00:00 2001 From: "marcins78@gmail.com" Date: Mon, 14 Nov 2011 11:51:34 +0000 Subject: [PATCH] "Castamir of Umbar" --- .../lotro/cards/set8/raider/Card8_051.java | 61 +++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set8/raider/Card8_051.java diff --git a/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set8/raider/Card8_051.java b/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set8/raider/Card8_051.java new file mode 100644 index 000000000..c59bd1655 --- /dev/null +++ b/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set8/raider/Card8_051.java @@ -0,0 +1,61 @@ +package com.gempukku.lotro.cards.set8.raider; + +import com.gempukku.lotro.cards.AbstractMinion; +import com.gempukku.lotro.cards.PlayConditions; +import com.gempukku.lotro.cards.effects.AddTokenEffect; +import com.gempukku.lotro.cards.effects.ExertCharactersEffect; +import com.gempukku.lotro.cards.effects.choose.ChooseAndPlayCardFromHandEffect; +import com.gempukku.lotro.common.*; +import com.gempukku.lotro.filters.Filters; +import com.gempukku.lotro.game.PhysicalCard; +import com.gempukku.lotro.game.state.LotroGame; +import com.gempukku.lotro.logic.actions.ActivateCardAction; +import com.gempukku.lotro.logic.effects.ChooseActiveCardEffect; +import com.gempukku.lotro.logic.timing.Action; + +import java.util.Collections; +import java.util.List; + +/** + * Set: Siege of Gondor + * Side: Shadow + * Culture: Raider + * Twilight Cost: 7 + * Type: Minion • Man + * Strength: 14 + * Vitality: 4 + * Site: 4 + * Game Text: Corsair. Enduring. Fierce. Shadow: Exert Castamir of Umbar and play a corsair to add 2 [RAIDER] tokens to + * a card that already has a [RAIDER] token on it. + */ +public class Card8_051 extends AbstractMinion { + public Card8_051() { + super(7, 14, 4, 4, Race.MAN, Culture.RAIDER, "Castamir of Umbar", true); + addKeyword(Keyword.CORSAIR); + addKeyword(Keyword.ENDURING); + addKeyword(Keyword.FIERCE); + } + + @Override + protected List getExtraPhaseActions(String playerId, LotroGame game, final PhysicalCard self) { + if (PlayConditions.canUseShadowCardDuringPhase(game, Phase.SHADOW, self, 0) + && PlayConditions.canSelfExert(self, game) + && PlayConditions.canPlayFromHand(playerId, game, Keyword.CORSAIR)) { + final ActivateCardAction action = new ActivateCardAction(self); + action.appendCost( + new ExertCharactersEffect(self, self)); + action.appendCost( + new ChooseAndPlayCardFromHandEffect(playerId, game.getGameState().getHand(playerId), Keyword.CORSAIR)); + action.appendEffect( + new ChooseActiveCardEffect(self, playerId, "Choose a card to add tokens to", Filters.hasToken(Token.RAIDER)) { + @Override + protected void cardSelected(LotroGame game, PhysicalCard card) { + action.insertEffect( + new AddTokenEffect(self, self, Token.RAIDER, 2)); + } + }); + return Collections.singletonList(action); + } + return null; + } +}