"Little Snuffler"

This commit is contained in:
marcins78@gmail.com
2012-01-03 11:58:22 +00:00
parent 32d03be7a6
commit 491e1ae056

View File

@@ -0,0 +1,56 @@
package com.gempukku.lotro.cards.set13.gollum;
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.choose.ChooseAndExertCharactersEffect;
import com.gempukku.lotro.cards.effects.choose.ChooseAndPlayCardFromDiscardEffect;
import com.gempukku.lotro.common.CardType;
import com.gempukku.lotro.common.Culture;
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;
import com.gempukku.lotro.logic.GameUtils;
import com.gempukku.lotro.logic.effects.ChooseAndWoundCharactersEffect;
/**
* Set: Bloodlines
* Side: Shadow
* Culture: Gollum
* Twilight Cost: 2
* Type: Event • Shadow
* Game Text: If the fellowship is in region 1, spot Gollum to wound a companion. If the fellowship is in region 2, spot
* Gollum to exert a companion. If the fellowship is in region 3, play a [GOLLUM] minion from your discard pile.
*/
public class Card13_052 extends AbstractEvent {
public Card13_052() {
super(Side.SHADOW, 2, Culture.GOLLUM, "Little Snuffler", Phase.SHADOW);
}
@Override
public boolean checkPlayRequirements(String playerId, LotroGame game, PhysicalCard self, int withTwilightRemoved, int twilightModifier, boolean ignoreRoamingPenalty, boolean ignoreCheckingDeadPile) {
int region = GameUtils.getRegion(game.getGameState());
return super.checkPlayRequirements(playerId, game, self, withTwilightRemoved, twilightModifier, ignoreRoamingPenalty, ignoreCheckingDeadPile)
&& (
((region == 1 || region == 2) && PlayConditions.canSpot(game, Filters.gollum))
|| (region == 3 && PlayConditions.canPlayFromDiscard(playerId, game, Culture.GOLLUM, CardType.MINION)));
}
@Override
public PlayEventAction getPlayCardAction(String playerId, LotroGame game, PhysicalCard self, int twilightModifier, boolean ignoreRoamingPenalty) {
PlayEventAction action = new PlayEventAction(self);
int region = GameUtils.getRegion(game.getGameState());
if (region == 1)
action.appendEffect(
new ChooseAndWoundCharactersEffect(action, playerId, 1, 1, CardType.COMPANION));
if (region == 2)
action.appendEffect(
new ChooseAndExertCharactersEffect(action, playerId, 1, 1, CardType.COMPANION));
if (region == 3)
action.appendEffect(
new ChooseAndPlayCardFromDiscardEffect(playerId, game, Culture.GOLLUM, CardType.MINION));
return action;
}
}