"Bow of Minas Tirith"
This commit is contained in:
@@ -72,6 +72,10 @@ public class PlayConditions {
|
||||
return (phase == null || game.getGameState().getCurrentPhase() == phase) && (game.getGameState().getCurrentSite() == self);
|
||||
}
|
||||
|
||||
public static boolean location(LotroGame game, Filterable... filters) {
|
||||
return Filters.and(filters).accepts(game.getGameState(), game.getModifiersQuerying(), game.getGameState().getCurrentSite());
|
||||
}
|
||||
|
||||
public static boolean stackedOn(PhysicalCard card, LotroGame game, Filterable... filters) {
|
||||
return Filters.and(filters).accepts(game.getGameState(), game.getModifiersQuerying(), card.getStackedOn());
|
||||
}
|
||||
|
||||
@@ -0,0 +1,54 @@
|
||||
package com.gempukku.lotro.cards.set11.gondor;
|
||||
|
||||
import com.gempukku.lotro.cards.AbstractAttachableFPPossession;
|
||||
import com.gempukku.lotro.cards.PlayConditions;
|
||||
import com.gempukku.lotro.cards.TriggerConditions;
|
||||
import com.gempukku.lotro.cards.effects.AddUntilEndOfPhaseModifierEffect;
|
||||
import com.gempukku.lotro.cards.effects.ExertCharactersEffect;
|
||||
import com.gempukku.lotro.cards.modifiers.ArcheryTotalModifier;
|
||||
import com.gempukku.lotro.common.*;
|
||||
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.timing.EffectResult;
|
||||
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Set: Shadows
|
||||
* Side: Free
|
||||
* Culture: Gondor
|
||||
* Twilight Cost: 1
|
||||
* Type: Possession • Ranged Weapon
|
||||
* Strength: +1
|
||||
* Game Text: Bearer must be a [GONDOR] Man. At the start of the archery phase, if bearer is at a battleground site,
|
||||
* you may exert him or her to make the fellowship archery total +1.
|
||||
*/
|
||||
public class Card11_058 extends AbstractAttachableFPPossession {
|
||||
public Card11_058() {
|
||||
super(1, 1, 0, Culture.GONDOR, PossessionClass.RANGED_WEAPON, "Bow of Minas Tirith");
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Filterable getValidTargetFilter(String playerId, LotroGame game, PhysicalCard self) {
|
||||
return Filters.and(Culture.GONDOR, Race.MAN);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<OptionalTriggerAction> getOptionalAfterTriggers(String playerId, LotroGame game, EffectResult effectResult, PhysicalCard self) {
|
||||
if (TriggerConditions.startOfPhase(game, effectResult, Phase.ARCHERY)
|
||||
&& PlayConditions.location(game, Keyword.BATTLEGROUND)
|
||||
&& PlayConditions.canExert(self, game, Filters.hasAttached(self))) {
|
||||
OptionalTriggerAction action = new OptionalTriggerAction(self);
|
||||
action.appendCost(
|
||||
new ExertCharactersEffect(self, self.getAttachedTo()));
|
||||
action.appendEffect(
|
||||
new AddUntilEndOfPhaseModifierEffect(
|
||||
new ArcheryTotalModifier(self, Side.FREE_PEOPLE, 1), Phase.ARCHERY));
|
||||
return Collections.singletonList(action);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user