"Knight of Gondor"

This commit is contained in:
marcins78@gmail.com
2011-10-17 14:36:28 +00:00
parent 9258b5fd30
commit b2a3ab839a

View File

@@ -0,0 +1,46 @@
package com.gempukku.lotro.cards.set5.gondor;
import com.gempukku.lotro.cards.AbstractCompanion;
import com.gempukku.lotro.cards.PlayConditions;
import com.gempukku.lotro.cards.effects.choose.ChooseAndDiscardCardsFromPlayEffect;
import com.gempukku.lotro.common.*;
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.HealCharactersEffect;
import com.gempukku.lotro.logic.timing.Action;
import java.util.Collections;
import java.util.List;
/**
* Set: Battle of Helm's Deep
* Side: Free
* Culture: Gondor
* Twilight Cost: 2
* Type: Companion • Man
* Strength: 5
* Vitality: 3
* Resistance: 6
* Game Text: Knight. Fellowship: Discard a [GONDOR] condition to heal this companion.
*/
public class Card5_036 extends AbstractCompanion {
public Card5_036() {
super(2, 5, 3, Culture.GONDOR, Race.MAN, null, "Knight of Gondor");
addKeyword(Keyword.KNIGHT);
}
@Override
protected List<? extends Action> getExtraInPlayPhaseActions(String playerId, LotroGame game, PhysicalCard self) {
if (PlayConditions.canUseFPCardDuringPhase(game.getGameState(), Phase.FELLOWSHIP, self)
&& PlayConditions.canBeDiscarded(self, game, Culture.GONDOR, CardType.CONDITION)) {
ActivateCardAction action = new ActivateCardAction(self);
action.appendCost(
new ChooseAndDiscardCardsFromPlayEffect(action, playerId, 1, 1, Culture.GONDOR, CardType.CONDITION));
action.appendEffect(
new HealCharactersEffect(playerId, self));
return Collections.singletonList(action);
}
return null;
}
}