Migrated Moria cards in set 6 to hjson
This commit is contained in:
@@ -1,48 +0,0 @@
|
||||
package com.gempukku.lotro.cards.set6.moria;
|
||||
|
||||
import com.gempukku.lotro.common.CardType;
|
||||
import com.gempukku.lotro.common.Culture;
|
||||
import com.gempukku.lotro.common.Keyword;
|
||||
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.cardtype.AbstractMinion;
|
||||
import com.gempukku.lotro.logic.modifiers.CantBeAssignedAgainstModifier;
|
||||
import com.gempukku.lotro.logic.modifiers.Modifier;
|
||||
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Set: Ents of Fangorn
|
||||
* Side: Shadow
|
||||
* Culture: Moria
|
||||
* Twilight Cost: 14
|
||||
* Type: Minion • Balrog
|
||||
* Strength: 17
|
||||
* Vitality: 5
|
||||
* Site: 4
|
||||
* Game Text: Damage +2. The twilight cost of The Balrog is -3 if you can spot a [MORIA] minion. The Balrog cannot
|
||||
* be assigned to skirmish companions or allies of strength less than 6.
|
||||
*/
|
||||
public class Card6_076 extends AbstractMinion {
|
||||
public Card6_076() {
|
||||
super(14, 17, 5, 4, Race.BALROG, Culture.MORIA, "The Balrog", "Terror of Flame and Shadow", true);
|
||||
addKeyword(Keyword.DAMAGE, 2);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getTwilightCostModifier(LotroGame game, PhysicalCard self, PhysicalCard target) {
|
||||
if (Filters.canSpot(game, Culture.MORIA, CardType.MINION))
|
||||
return -3;
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<? extends Modifier> getInPlayModifiers(LotroGame game, PhysicalCard self) {
|
||||
return Collections.singletonList(
|
||||
new CantBeAssignedAgainstModifier(self, null,
|
||||
Filters.and(Filters.or(CardType.COMPANION, CardType.ALLY), Filters.lessStrengthThan(6)), self));
|
||||
}
|
||||
}
|
||||
@@ -1,52 +0,0 @@
|
||||
package com.gempukku.lotro.cards.set6.moria;
|
||||
|
||||
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.cardtype.AbstractPermanent;
|
||||
import com.gempukku.lotro.logic.effects.SelfDiscardEffect;
|
||||
import com.gempukku.lotro.logic.effects.choose.ChooseAndAddUntilEOPStrengthBonusEffect;
|
||||
import com.gempukku.lotro.logic.modifiers.Modifier;
|
||||
import com.gempukku.lotro.logic.modifiers.TwilightCostModifier;
|
||||
import com.gempukku.lotro.logic.modifiers.condition.LocationCondition;
|
||||
import com.gempukku.lotro.logic.timing.PlayConditions;
|
||||
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Set: Ents of Fangorn
|
||||
* Side: Shadow
|
||||
* Culture: Moria
|
||||
* Twilight Cost: 0
|
||||
* Type: Condition
|
||||
* Game Text: Plays to your support area. At sites 2T and 3T, The Balrog's twilight cost is -3. Skirmish: Discard this
|
||||
* condition to make a unique [MORIA] minion strength +3.
|
||||
*/
|
||||
public class Card6_077 extends AbstractPermanent {
|
||||
public Card6_077() {
|
||||
super(Side.SHADOW, 0, CardType.CONDITION, Culture.MORIA, "Durin's Tower", null, true);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<? extends Modifier> getInPlayModifiers(LotroGame game, PhysicalCard self) {
|
||||
return Collections.singletonList(
|
||||
new TwilightCostModifier(self, Filters.balrog, new LocationCondition(Filters.or(Filters.siteNumber(2), Filters.siteNumber(3)), Filters.siteBlock(SitesBlock.TWO_TOWERS)), -3));
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<? extends ActivateCardAction> getPhaseActionsInPlay(String playerId, LotroGame game, PhysicalCard self) {
|
||||
if (PlayConditions.canUseShadowCardDuringPhase(game, Phase.SKIRMISH, self, 0)
|
||||
&& PlayConditions.canSelfDiscard(self, game)) {
|
||||
ActivateCardAction action = new ActivateCardAction(self);
|
||||
action.appendCost(
|
||||
new SelfDiscardEffect(self));
|
||||
action.appendEffect(
|
||||
new ChooseAndAddUntilEOPStrengthBonusEffect(action, self, playerId, 3, Culture.MORIA, CardType.MINION, Filters.unique));
|
||||
return Collections.singletonList(action);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
@@ -304,18 +304,10 @@
|
||||
type: activated
|
||||
phase: assignment
|
||||
effect: [
|
||||
{
|
||||
type: memorizeNumber
|
||||
amount: {
|
||||
type: forEachStrength
|
||||
filter: bearer
|
||||
}
|
||||
memory: bearerStrength
|
||||
}
|
||||
{
|
||||
type: assignFPCharacterToSkirmish
|
||||
fpCharacter: bearer
|
||||
against: choose(culture(isengard),minion,strengthLessThan(memory(bearerStrength)))
|
||||
against: choose(culture(isengard),minion,strengthLessThanFilter(bearer))
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@@ -27,17 +27,24 @@
|
||||
vitality: 5
|
||||
site: 4
|
||||
keywords: Damage+2
|
||||
/*requires: {
|
||||
|
||||
}
|
||||
effects: [
|
||||
{
|
||||
|
||||
type: modifyOwnCost
|
||||
requires: {
|
||||
type: canSpot
|
||||
filter: culture(moria),minion
|
||||
}
|
||||
amount: -3
|
||||
}
|
||||
{
|
||||
|
||||
type: modifier
|
||||
modifier: {
|
||||
type: cantBeAssignedToSkirmishAgainst
|
||||
minion: self
|
||||
fpCharacter: strengthLessThan(6)
|
||||
}
|
||||
}
|
||||
]*/
|
||||
]
|
||||
gametext: <b>Damage +2</b>.<br>The twilight cost of The Balrog is -3 if you can spot a [moria] minion.<br>The Balrog cannot be assigned to skirmish companions or allies of strength less than 6.
|
||||
lore: ...he burst into new flame.'
|
||||
promotext: ""
|
||||
@@ -71,17 +78,33 @@
|
||||
twilight: 0
|
||||
type: Condition
|
||||
keywords: Support Area
|
||||
/*requires: {
|
||||
|
||||
}
|
||||
effects: [
|
||||
{
|
||||
|
||||
type: modifier
|
||||
modifier: {
|
||||
type: modifyCost
|
||||
requires: {
|
||||
type: location
|
||||
filter: siteNumber(2-3),siteBlock(two towers)
|
||||
}
|
||||
filter: name(The Balrog)
|
||||
amount: -3
|
||||
}
|
||||
}
|
||||
{
|
||||
|
||||
type: activated
|
||||
phase: skirmish
|
||||
cost: {
|
||||
type: discard
|
||||
filter: self
|
||||
}
|
||||
effect: {
|
||||
type: modifyStrength
|
||||
filter: choose(unique,culture(moria),minion)
|
||||
amount: 3
|
||||
}
|
||||
}
|
||||
]*/
|
||||
]
|
||||
gametext: Plays to your support area. At sites 2[T] and 3[T], The Balrog's twilight cost is -3.<br><b>Skirmish:</b> Discard this condition to make a unique [moria] minion strength +3.
|
||||
lore: ...carved in the living rock of Zirakzigil, the pinnacle of the Silvertine.'
|
||||
promotext: ""
|
||||
@@ -446,6 +446,18 @@ public class FilterFactory {
|
||||
|
||||
return (actionContext) -> Filters.siteNumberBetweenInclusive(min, max);
|
||||
});
|
||||
parameterFilters.put("strengthlessthanfilter",
|
||||
(parameter, environment) -> {
|
||||
FilterableSource filter = environment.getFilterFactory().createFilter(parameter, environment);
|
||||
return (actionContext) -> {
|
||||
int strength = 0;
|
||||
LotroGame game = actionContext.getGame();
|
||||
for (PhysicalCard physicalCard : Filters.filterActive(game, filter.getFilterable(actionContext))) {
|
||||
strength += game.getModifiersQuerying().getStrength(game, physicalCard);
|
||||
}
|
||||
return Filters.lessStrengthThan(strength);
|
||||
};
|
||||
});
|
||||
parameterFilters.put("strengthlessthan",
|
||||
(parameter, environment) -> {
|
||||
final ValueSource valueSource = ValueResolver.resolveEvaluator(parameter, environment);
|
||||
|
||||
Reference in New Issue
Block a user