"Gimli"
This commit is contained in:
@@ -0,0 +1,59 @@
|
||||
package com.gempukku.lotro.cards.set4.dwarven;
|
||||
|
||||
import com.gempukku.lotro.cards.AbstractCompanion;
|
||||
import com.gempukku.lotro.cards.PlayConditions;
|
||||
import com.gempukku.lotro.cards.effects.AddUntilEndOfPhaseModifierEffect;
|
||||
import com.gempukku.lotro.cards.effects.ExertCharactersEffect;
|
||||
import com.gempukku.lotro.cards.modifiers.StrengthModifier;
|
||||
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.ActivateCardAction;
|
||||
import com.gempukku.lotro.logic.effects.ChooseActiveCardEffect;
|
||||
import com.gempukku.lotro.logic.timing.Action;
|
||||
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Set: The Two Towers
|
||||
* Side: Free
|
||||
* Culture: Dwarven
|
||||
* Twilight Cost: 2
|
||||
* Type: Companion • Dwarf
|
||||
* Strength: 6
|
||||
* Vitality: 3
|
||||
* Resistance: 6
|
||||
* Signet: Gandalf
|
||||
* Game Text: Damage +1.
|
||||
* Skirmish: Exert Gimli to make an unbound companion strength +1 (or +2 if that companion is Legolas).
|
||||
*/
|
||||
public class Card4_049 extends AbstractCompanion {
|
||||
public Card4_049() {
|
||||
super(2, 6, 3, Culture.DWARVEN, Race.DWARF, Signet.GANDALF, "Gimli", true);
|
||||
addKeyword(Keyword.DAMAGE);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected List<? extends Action> getExtraInPlayPhaseActions(String playerId, LotroGame game, final PhysicalCard self) {
|
||||
if (PlayConditions.canUseFPCardDuringPhase(game.getGameState(), Phase.SKIRMISH, self)
|
||||
&& PlayConditions.canExert(self, game.getGameState(), game.getModifiersQuerying(), self)) {
|
||||
final ActivateCardAction action = new ActivateCardAction(self, Keyword.SKIRMISH);
|
||||
action.appendCost(
|
||||
new ExertCharactersEffect(self, self));
|
||||
action.appendEffect(
|
||||
new ChooseActiveCardEffect(self, playerId, "Choose unbound companion", Filters.unboundCompanion()) {
|
||||
@Override
|
||||
protected void cardSelected(PhysicalCard card) {
|
||||
int bonus = (card.getBlueprint().getName().equals("Legolas")) ? 2 : 1;
|
||||
action.insertEffect(
|
||||
new AddUntilEndOfPhaseModifierEffect(
|
||||
new StrengthModifier(self, Filters.sameCard(card), bonus), Phase.SKIRMISH));
|
||||
}
|
||||
});
|
||||
return Collections.singletonList(action);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user