"Bilbo"
This commit is contained in:
@@ -0,0 +1,62 @@
|
|||||||
|
package com.gempukku.lotro.cards.set1.shire;
|
||||||
|
|
||||||
|
import com.gempukku.lotro.cards.AbstractAlly;
|
||||||
|
import com.gempukku.lotro.cards.PlayConditions;
|
||||||
|
import com.gempukku.lotro.cards.effects.ExertCharacterEffect;
|
||||||
|
import com.gempukku.lotro.cards.effects.PutCardFromDiscardOnBottomOfDeckEffect;
|
||||||
|
import com.gempukku.lotro.cards.effects.ShuffleDeckEffect;
|
||||||
|
import com.gempukku.lotro.common.Culture;
|
||||||
|
import com.gempukku.lotro.common.Keyword;
|
||||||
|
import com.gempukku.lotro.common.Phase;
|
||||||
|
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.CostToEffectAction;
|
||||||
|
import com.gempukku.lotro.logic.effects.ChooseArbitraryCardsEffect;
|
||||||
|
import com.gempukku.lotro.logic.timing.Action;
|
||||||
|
|
||||||
|
import java.util.LinkedList;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Set: The Fellowship of the Ring
|
||||||
|
* Side: Free
|
||||||
|
* Culture: Shire
|
||||||
|
* Twilight Cost: 2
|
||||||
|
* Type: Ally • Home 3 • Hobbit
|
||||||
|
* Strength: 2
|
||||||
|
* Vitality: 3
|
||||||
|
* Site: 3
|
||||||
|
* Game Text: Fellowship: Exert Bilbo to shuffle a [SHIRE] card from your discard pile into your draw deck.
|
||||||
|
*/
|
||||||
|
public class Card1_284 extends AbstractAlly {
|
||||||
|
public Card1_284() {
|
||||||
|
super(2, 3, 2, 3, Culture.SHIRE, "Bilbo", true);
|
||||||
|
addKeyword(Keyword.HOBBIT);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<? extends Action> getPlayablePhaseActions(final String playerId, LotroGame game, PhysicalCard self) {
|
||||||
|
List<Action> actions = new LinkedList<Action>();
|
||||||
|
appendPlayAllyActions(actions, game, self);
|
||||||
|
appendHealAllyActions(actions, game, self);
|
||||||
|
|
||||||
|
if (PlayConditions.canUseFPCardDuringPhase(game.getGameState(), Phase.FELLOWSHIP, self)
|
||||||
|
&& PlayConditions.canExert(game.getGameState(), game.getModifiersQuerying(), self)) {
|
||||||
|
final CostToEffectAction action = new CostToEffectAction(self, Keyword.FELLOWSHIP, "Exert Bilbo to shuffle a SHIRE card from your discard pile into your draw deck.");
|
||||||
|
action.addCost(new ExertCharacterEffect(self));
|
||||||
|
action.addEffect(
|
||||||
|
new ChooseArbitraryCardsEffect(playerId, "Choose SHIRE card", game.getGameState().getDiscard(playerId), Filters.culture(Culture.SHIRE), 1, 1) {
|
||||||
|
@Override
|
||||||
|
protected void cardsSelected(List<PhysicalCard> selectedCards) {
|
||||||
|
PhysicalCard card = selectedCards.get(0);
|
||||||
|
action.addEffect(new PutCardFromDiscardOnBottomOfDeckEffect(card));
|
||||||
|
action.addEffect(new ShuffleDeckEffect(playerId));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
);
|
||||||
|
actions.add(action);
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -13,16 +13,16 @@ import java.util.List;
|
|||||||
public abstract class ChooseArbitraryCardsEffect extends UnrespondableEffect {
|
public abstract class ChooseArbitraryCardsEffect extends UnrespondableEffect {
|
||||||
private String _playerId;
|
private String _playerId;
|
||||||
private String _choiceText;
|
private String _choiceText;
|
||||||
private List<PhysicalCard> _cards;
|
private List<? extends PhysicalCard> _cards;
|
||||||
private Filter _filter;
|
private Filter _filter;
|
||||||
private int _minimum;
|
private int _minimum;
|
||||||
private int _maximum;
|
private int _maximum;
|
||||||
|
|
||||||
public ChooseArbitraryCardsEffect(String playerId, String choiceText, List<PhysicalCard> cards, int minimum, int maximum) {
|
public ChooseArbitraryCardsEffect(String playerId, String choiceText, List<? extends PhysicalCard> cards, int minimum, int maximum) {
|
||||||
this(playerId, choiceText, cards, Filters.any(), minimum, maximum);
|
this(playerId, choiceText, cards, Filters.any(), minimum, maximum);
|
||||||
}
|
}
|
||||||
|
|
||||||
public ChooseArbitraryCardsEffect(String playerId, String choiceText, List<PhysicalCard> cards, Filter filter, int minimum, int maximum) {
|
public ChooseArbitraryCardsEffect(String playerId, String choiceText, List<? extends PhysicalCard> cards, Filter filter, int minimum, int maximum) {
|
||||||
_playerId = playerId;
|
_playerId = playerId;
|
||||||
_choiceText = choiceText;
|
_choiceText = choiceText;
|
||||||
_cards = cards;
|
_cards = cards;
|
||||||
|
|||||||
Reference in New Issue
Block a user