"Knocked on the Head"

This commit is contained in:
marcins78@gmail.com
2011-10-16 18:56:31 +00:00
parent 9c17cf3225
commit 31dd9cbe28

View File

@@ -0,0 +1,41 @@
package com.gempukku.lotro.cards.set4.shire;
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.ChooseAndPlayCardFromDiscardEffect;
import com.gempukku.lotro.common.Culture;
import com.gempukku.lotro.common.Phase;
import com.gempukku.lotro.common.Race;
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;
/**
* Set: The Two Towers
* Side: Free
* Culture: Shire
* Twilight Cost: 0
* Type: Event
* Game Text: Regroup: Play an unbound Hobbit from your discard pile.
*/
public class Card4_308 extends AbstractEvent {
public Card4_308() {
super(Side.FREE_PEOPLE, 0, Culture.SHIRE, "Knocked on the Head", Phase.REGROUP);
}
@Override
public boolean checkPlayRequirements(String playerId, LotroGame game, PhysicalCard self, int twilightModifier) {
return super.checkPlayRequirements(playerId, game, self, twilightModifier)
&& PlayConditions.canPlayFromDiscard(playerId, game, Race.HOBBIT, Filters.unboundCompanion);
}
@Override
public PlayEventAction getPlayCardAction(String playerId, LotroGame game, PhysicalCard self, int twilightModifier) {
PlayEventAction action = new PlayEventAction(self);
action.appendEffect(
new ChooseAndPlayCardFromDiscardEffect(playerId, game.getGameState().getDiscard(playerId), Race.HOBBIT, Filters.unboundCompanion));
return action;
}
}