"Hillman Rabble"
This commit is contained in:
@@ -0,0 +1,66 @@
|
||||
package com.gempukku.lotro.cards.set4.dunland;
|
||||
|
||||
import com.gempukku.lotro.cards.AbstractMinion;
|
||||
import com.gempukku.lotro.cards.PlayConditions;
|
||||
import com.gempukku.lotro.cards.effects.StackCardFromPlayEffect;
|
||||
import com.gempukku.lotro.common.CardType;
|
||||
import com.gempukku.lotro.common.Culture;
|
||||
import com.gempukku.lotro.common.Phase;
|
||||
import com.gempukku.lotro.common.Race;
|
||||
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.OptionalTriggerAction;
|
||||
import com.gempukku.lotro.logic.effects.ChooseActiveCardEffect;
|
||||
import com.gempukku.lotro.logic.timing.Action;
|
||||
import com.gempukku.lotro.logic.timing.EffectResult;
|
||||
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Set: The Two Towers
|
||||
* Side: Shadow
|
||||
* Culture: Dunland
|
||||
* Twilight Cost: 4
|
||||
* Type: Minion • Man
|
||||
* Strength: 10
|
||||
* Vitality: 1
|
||||
* Site: 3
|
||||
* Game Text: Each time this minion wins a skirmish, you may stack it on a site you control. Shadow: If stacked on
|
||||
* a site you control, play this minion. Its twilight cost is -2.
|
||||
*/
|
||||
public class Card4_024 extends AbstractMinion {
|
||||
public Card4_024() {
|
||||
super(4, 10, 1, 3, Race.MAN, Culture.DUNLAND, "Hillman Rabble");
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<OptionalTriggerAction> getOptionalAfterTriggers(String playerId, LotroGame game, EffectResult effectResult, final PhysicalCard self) {
|
||||
if (PlayConditions.winsSkirmish(effectResult, self)
|
||||
&& PlayConditions.controllsSite(game.getGameState(), game.getModifiersQuerying(), playerId)) {
|
||||
final OptionalTriggerAction action = new OptionalTriggerAction(self);
|
||||
action.appendEffect(
|
||||
new ChooseActiveCardEffect(self, playerId, "Choose site you control", Filters.siteControlled(playerId)) {
|
||||
@Override
|
||||
protected void cardSelected(PhysicalCard card) {
|
||||
action.insertEffect(
|
||||
new StackCardFromPlayEffect(self, card));
|
||||
}
|
||||
});
|
||||
return Collections.singletonList(action);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<? extends Action> getPhaseActionsFromStacked(String playerId, LotroGame game, PhysicalCard self) {
|
||||
if (PlayConditions.canUseStackedShadowCardDuringPhase(game.getGameState(), Phase.SHADOW, self, 0)
|
||||
&& self.getStackedOn().getBlueprint().getCardType() == CardType.SITE
|
||||
&& playerId.equals(self.getStackedOn().getCardController())
|
||||
&& checkPlayRequirements(playerId, game, self, -2)) {
|
||||
return Collections.singletonList(getPlayCardAction(playerId, game, self, -2));
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user