"Too Long Have These Peasants Stood"
This commit is contained in:
@@ -203,6 +203,10 @@ public class PlayConditions {
|
||||
return Filters.findFirstActive(gameState, modifiersQuerying, Filters.siteControlled(playerId)) != null;
|
||||
}
|
||||
|
||||
public static boolean winsSkirmish(LotroGame game, EffectResult effectResult, Filterable... filters) {
|
||||
return winsSkirmish(game.getGameState(), game.getModifiersQuerying(), effectResult, filters);
|
||||
}
|
||||
|
||||
public static boolean winsSkirmish(EffectResult effectResult, PhysicalCard character) {
|
||||
EffectResult.Type effectType = effectResult.getType();
|
||||
if (effectType == EffectResult.Type.RESOLVE_SKIRMISH || effectType == EffectResult.Type.OVERWHELM_IN_SKIRMISH) {
|
||||
|
||||
@@ -0,0 +1,42 @@
|
||||
package com.gempukku.lotro.cards.set6.dunland;
|
||||
|
||||
import com.gempukku.lotro.cards.AbstractResponseEvent;
|
||||
import com.gempukku.lotro.cards.PlayConditions;
|
||||
import com.gempukku.lotro.cards.actions.PlayEventAction;
|
||||
import com.gempukku.lotro.common.CardType;
|
||||
import com.gempukku.lotro.common.Culture;
|
||||
import com.gempukku.lotro.common.Race;
|
||||
import com.gempukku.lotro.common.Side;
|
||||
import com.gempukku.lotro.game.PhysicalCard;
|
||||
import com.gempukku.lotro.game.state.LotroGame;
|
||||
import com.gempukku.lotro.logic.effects.DiscardCardsFromPlayEffect;
|
||||
import com.gempukku.lotro.logic.timing.EffectResult;
|
||||
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Set: Ents of Fangorn
|
||||
* Side: Shadow
|
||||
* Culture: Dunland
|
||||
* Twilight Cost: 2
|
||||
* Type: Event
|
||||
* Game Text: Response: If a [DUNLAND] Man wins a skirmish, discard all conditions.
|
||||
*/
|
||||
public class Card6_008 extends AbstractResponseEvent {
|
||||
public Card6_008() {
|
||||
super(Side.SHADOW, 2, Culture.DUNLAND, "Too Long Have These Peasants Stood");
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<PlayEventAction> getOptionalAfterActions(String playerId, LotroGame game, EffectResult effectResult, PhysicalCard self) {
|
||||
if (PlayConditions.canPayForShadowCard(game, self, 0)
|
||||
&& PlayConditions.winsSkirmish(game, effectResult, Culture.DUNLAND, Race.MAN)) {
|
||||
PlayEventAction action = new PlayEventAction(self);
|
||||
action.appendEffect(
|
||||
new DiscardCardsFromPlayEffect(self, CardType.CONDITION));
|
||||
return Collections.singletonList(action);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,6 @@
|
||||
package com.gempukku.lotro.logic.effects;
|
||||
|
||||
import com.gempukku.lotro.common.Filterable;
|
||||
import com.gempukku.lotro.common.Zone;
|
||||
import com.gempukku.lotro.filters.Filter;
|
||||
import com.gempukku.lotro.game.PhysicalCard;
|
||||
@@ -20,8 +21,8 @@ public class DiscardCardsFromPlayEffect extends AbstractPreventableCardEffect {
|
||||
_source = source;
|
||||
}
|
||||
|
||||
public DiscardCardsFromPlayEffect(PhysicalCard source, Filter filter) {
|
||||
super(filter);
|
||||
public DiscardCardsFromPlayEffect(PhysicalCard source, Filterable... filters) {
|
||||
super(filters);
|
||||
_source = source;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user