Migrated Site cards in set 15 to hjson

This commit is contained in:
MarcinSc
2024-05-25 19:20:12 +07:00
parent 754e42b9f3
commit 880f579c7e
10 changed files with 132 additions and 420 deletions

View File

@@ -1,92 +0,0 @@
package com.gempukku.lotro.cards.set15;
import com.gempukku.lotro.common.CardType;
import com.gempukku.lotro.common.Keyword;
import com.gempukku.lotro.common.Phase;
import com.gempukku.lotro.filters.Filter;
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.actions.RequiredTriggerAction;
import com.gempukku.lotro.logic.cardtype.AbstractAttachable;
import com.gempukku.lotro.logic.effects.AddBurdenEffect;
import com.gempukku.lotro.logic.effects.NegateWoundEffect;
import com.gempukku.lotro.logic.effects.PutOnTheOneRingEffect;
import com.gempukku.lotro.logic.effects.WoundCharactersEffect;
import com.gempukku.lotro.logic.modifiers.Condition;
import com.gempukku.lotro.logic.modifiers.KeywordModifier;
import com.gempukku.lotro.logic.modifiers.Modifier;
import com.gempukku.lotro.logic.modifiers.ModifierFlag;
import com.gempukku.lotro.logic.timing.Effect;
import com.gempukku.lotro.logic.timing.PlayConditions;
import com.gempukku.lotro.logic.timing.TriggerConditions;
import java.util.Collections;
import java.util.LinkedList;
import java.util.List;
/**
* Set: The Hunters
* Type: The One Ring
* Vitality: +2
* Game Text: While wearing The One Ring, the Ring-bearer gains hunter 3, and each time he or she is about to take
* a wound in a skirmish, add a burden instead. Skirmish: Add a burden to wear The One Ring until the regroup phase.
*/
public class Card15_001 extends AbstractAttachable {
public Card15_001() {
super(null, CardType.THE_ONE_RING, 0, null, null, "The One Ring", "The Ring of Doom", true);
}
@Override
public Filter getValidTargetFilter(String playerId, LotroGame game, PhysicalCard self) {
return Filters.none;
}
@Override
public int getVitality() {
return 2;
}
@Override
public List<? extends Modifier> getInPlayModifiers(LotroGame game, PhysicalCard self) {
List<Modifier> modifiers = new LinkedList<>();
modifiers.add(
new KeywordModifier(self, Filters.hasAttached(self),
new Condition() {
@Override
public boolean isFullfilled(LotroGame game) {
return !game.getModifiersQuerying().hasFlagActive(game, ModifierFlag.RING_TEXT_INACTIVE) && game.getGameState().isWearingRing();
}
}, Keyword.HUNTER, 3));
return modifiers;
}
@Override
public List<RequiredTriggerAction> getRequiredBeforeTriggers(LotroGame game, Effect effect, PhysicalCard self) {
if (TriggerConditions.isGettingWounded(effect, game, Filters.hasAttached(self))
&& game.getGameState().isWearingRing()
&& !game.getModifiersQuerying().hasFlagActive(game, ModifierFlag.RING_TEXT_INACTIVE)) {
WoundCharactersEffect woundEffect = (WoundCharactersEffect) effect;
RequiredTriggerAction action = new RequiredTriggerAction(self);
action.appendEffect(new NegateWoundEffect(woundEffect, self.getAttachedTo()));
action.appendEffect(new AddBurdenEffect(self.getOwner(), self, 1));
return Collections.singletonList(action);
}
return null;
}
@Override
public List<? extends ActivateCardAction> getPhaseActionsInPlay(String playerId, LotroGame game, final PhysicalCard self) {
if (PlayConditions.canUseFPCardDuringPhase(game, Phase.SKIRMISH, self)
&& !game.getModifiersQuerying().hasFlagActive(game, ModifierFlag.RING_TEXT_INACTIVE)) {
ActivateCardAction action = new ActivateCardAction(self);
action.appendCost(
new AddBurdenEffect(self.getOwner(), self, 1));
action.appendEffect(
new PutOnTheOneRingEffect());
return Collections.singletonList(action);
}
return null;
}
}

View File

@@ -1,30 +0,0 @@
package com.gempukku.lotro.cards.set15.site;
import com.gempukku.lotro.common.Keyword;
import com.gempukku.lotro.common.Side;
import com.gempukku.lotro.game.PhysicalCard;
import com.gempukku.lotro.game.state.LotroGame;
import com.gempukku.lotro.logic.cardtype.AbstractShadowsSite;
import com.gempukku.lotro.logic.modifiers.ArcheryTotalModifier;
import com.gempukku.lotro.logic.modifiers.Modifier;
import java.util.Collections;
import java.util.List;
/**
* Set: The Hunters
* Twilight Cost: 0
* Type: Site
* Game Text: River. The fellowship archery total is -3.
*/
public class Card15_187 extends AbstractShadowsSite {
public Card15_187() {
super("Anduin River", 0, Direction.LEFT);
addKeyword(Keyword.RIVER);
}
@Override
public List<? extends Modifier> getInPlayModifiers(LotroGame game, PhysicalCard self) {
return Collections.singletonList(new ArcheryTotalModifier(self, Side.FREE_PEOPLE, -3));
}
}

View File

@@ -1,56 +0,0 @@
package com.gempukku.lotro.cards.set15.site;
import com.gempukku.lotro.common.CardType;
import com.gempukku.lotro.common.Keyword;
import com.gempukku.lotro.common.Phase;
import com.gempukku.lotro.filters.Filter;
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.RequiredTriggerAction;
import com.gempukku.lotro.logic.cardtype.AbstractShadowsSite;
import com.gempukku.lotro.logic.modifiers.Modifier;
import com.gempukku.lotro.logic.modifiers.TwilightCostModifier;
import com.gempukku.lotro.logic.modifiers.condition.PhaseCondition;
import com.gempukku.lotro.logic.timing.EffectResult;
import com.gempukku.lotro.logic.timing.PlayConditions;
import com.gempukku.lotro.logic.timing.TriggerConditions;
import java.util.Collections;
import java.util.List;
/**
* Set: The Hunters
* Twilight Cost: 0
* Type: Site
* Game Text: Underground. The twilight cost of the first hunter minion played each shadow phase is -2.
*/
public class Card15_188 extends AbstractShadowsSite {
public Card15_188() {
super("Breeding pit of Isengard", 0, Direction.LEFT);
addKeyword(Keyword.UNDERGROUND);
}
@Override
public List<? extends Modifier> getInPlayModifiers(LotroGame game, final PhysicalCard self) {
return Collections.singletonList(new TwilightCostModifier(self,
Filters.and(
CardType.MINION,
Keyword.HUNTER,
new Filter() {
@Override
public boolean accepts(LotroGame game, PhysicalCard physicalCard) {
return game.getModifiersQuerying().getUntilEndOfPhaseLimitCounter(self, Phase.SHADOW).getUsedLimit() < 1;
}
}), new PhaseCondition(Phase.SHADOW), -2));
}
@Override
public List<RequiredTriggerAction> getRequiredAfterTriggers(LotroGame game, EffectResult effectResult, PhysicalCard self) {
if (TriggerConditions.played(game, effectResult, Filters.and(CardType.MINION, Keyword.HUNTER))
&& PlayConditions.isPhase(game, Phase.SHADOW))
game.getModifiersQuerying().getUntilEndOfPhaseLimitCounter(self, Phase.SHADOW).incrementToLimit(1, 1);
return null;
}
}

View File

@@ -1,43 +0,0 @@
package com.gempukku.lotro.cards.set15.site;
import com.gempukku.lotro.logic.cardtype.AbstractShadowsSite;
import com.gempukku.lotro.logic.timing.PlayConditions;
import com.gempukku.lotro.logic.timing.TriggerConditions;
import com.gempukku.lotro.common.CardType;
import com.gempukku.lotro.common.Keyword;
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.RequiredTriggerAction;
import com.gempukku.lotro.logic.effects.AddThreatsEffect;
import com.gempukku.lotro.logic.timing.EffectResult;
import java.util.Collections;
import java.util.List;
/**
* Set: The Hunters
* Twilight Cost: 1
* Type: Site
* Game Text: When the Fellowship moves to this site, add a threat (or 2 if you can spot a hunter minion)
* for each companion over 4.
*/
public class Card15_189 extends AbstractShadowsSite {
public Card15_189() {
super("City Gates", 1, Direction.RIGHT);
}
@Override
public List<RequiredTriggerAction> getRequiredAfterTriggers(LotroGame game, EffectResult effectResult, PhysicalCard self) {
if (TriggerConditions.movesTo(game, effectResult, self)) {
RequiredTriggerAction action = new RequiredTriggerAction(self);
int threats = PlayConditions.canSpot(game, CardType.MINION, Keyword.HUNTER) ? 2 : 1;
int companions = Filters.countActive(game, CardType.COMPANION);
if (companions > 4)
action.appendEffect(
new AddThreatsEffect(game.getGameState().getCurrentPlayerId(), self, (companions - 4) * threats));
return Collections.singletonList(action);
}
return null;
}
}

View File

@@ -1,45 +0,0 @@
package com.gempukku.lotro.cards.set15.site;
import com.gempukku.lotro.logic.cardtype.AbstractShadowsSite;
import com.gempukku.lotro.logic.timing.PlayConditions;
import com.gempukku.lotro.logic.timing.TriggerConditions;
import com.gempukku.lotro.logic.effects.choose.ChooseAndExertCharactersEffect;
import com.gempukku.lotro.logic.effects.choose.ChooseAndPlayCardFromDeckEffect;
import com.gempukku.lotro.common.CardType;
import com.gempukku.lotro.common.Keyword;
import com.gempukku.lotro.common.Phase;
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: The Hunters
* Twilight Cost: 3
* Type: Site
* Game Text: At the start of the Fellowship phase, you may exert two hunter companions to play a hunter companion
* from your draw deck.
*/
public class Card15_190 extends AbstractShadowsSite {
public Card15_190() {
super("East Wall of Rohan", 3, Direction.RIGHT);
}
@Override
public List<OptionalTriggerAction> getOptionalAfterTriggers(String playerId, LotroGame game, EffectResult effectResult, PhysicalCard self) {
if (TriggerConditions.startOfPhase(game, effectResult, Phase.FELLOWSHIP)
&& game.getGameState().getCurrentPlayerId().equals(playerId)
&& PlayConditions.canExert(self, game, 1, 2, CardType.COMPANION, Keyword.HUNTER)) {
OptionalTriggerAction action = new OptionalTriggerAction(self);
action.appendCost(
new ChooseAndExertCharactersEffect(action, playerId, 2, 2, CardType.COMPANION, Keyword.HUNTER));
action.appendEffect(
new ChooseAndPlayCardFromDeckEffect(playerId, CardType.COMPANION, Keyword.HUNTER));
return Collections.singletonList(action);
}
return null;
}
}

View File

@@ -1,39 +0,0 @@
package com.gempukku.lotro.cards.set15.site;
import com.gempukku.lotro.logic.cardtype.AbstractShadowsSite;
import com.gempukku.lotro.logic.timing.TriggerConditions;
import com.gempukku.lotro.logic.modifiers.evaluator.CountCulturesEvaluator;
import com.gempukku.lotro.common.Keyword;
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.RequiredTriggerAction;
import com.gempukku.lotro.logic.effects.AddTwilightEffect;
import com.gempukku.lotro.logic.timing.EffectResult;
import java.util.Collections;
import java.util.List;
/**
* Set: The Hunters
* Twilight Cost: 0
* Type: Site
* Game Text: Battleground. Each time the fellowship moves to this site add (1) for each culture you can spot.
*/
public class Card15_191 extends AbstractShadowsSite {
public Card15_191() {
super("Gate of Mordor", 0, Direction.LEFT);
addKeyword(Keyword.BATTLEGROUND);
}
@Override
public List<RequiredTriggerAction> getRequiredAfterTriggers(LotroGame game, EffectResult effectResult, PhysicalCard self) {
if (TriggerConditions.movesTo(game, effectResult, self)) {
RequiredTriggerAction action = new RequiredTriggerAction(self);
action.appendEffect(
new AddTwilightEffect(self, new CountCulturesEvaluator(Filters.any).evaluateExpression(game, null)));
return Collections.singletonList(action);
}
return null;
}
}

View File

@@ -1,43 +0,0 @@
package com.gempukku.lotro.cards.set15.site;
import com.gempukku.lotro.logic.cardtype.AbstractShadowsSite;
import com.gempukku.lotro.logic.timing.TriggerConditions;
import com.gempukku.lotro.logic.effects.choose.ChooseAndExertCharactersEffect;
import com.gempukku.lotro.common.CardType;
import com.gempukku.lotro.common.Keyword;
import com.gempukku.lotro.filters.Filters;
import com.gempukku.lotro.game.PhysicalCard;
import com.gempukku.lotro.game.state.LotroGame;
import com.gempukku.lotro.logic.GameUtils;
import com.gempukku.lotro.logic.actions.OptionalTriggerAction;
import com.gempukku.lotro.logic.timing.EffectResult;
import java.util.Collections;
import java.util.List;
/**
* Set: The Hunters
* Twilight Cost: 1
* Type: Site
* Game Text: Battleground. Each time a follower is transferred to a character, the first Shadow player may exert
* a companion twice.
*/
public class Card15_192 extends AbstractShadowsSite {
public Card15_192() {
super("Isengard Ruined", 1, Direction.RIGHT);
addKeyword(Keyword.BATTLEGROUND);
}
@Override
public List<OptionalTriggerAction> getOptionalAfterTriggers(String playerId, LotroGame game, EffectResult effectResult, PhysicalCard self) {
final String firstShadowPlayer = GameUtils.getFirstShadowPlayer(game);
if (TriggerConditions.transferredCard(game, effectResult, CardType.FOLLOWER, null, Filters.character)
&& playerId.equals(firstShadowPlayer)) {
OptionalTriggerAction action = new OptionalTriggerAction(self);
action.appendEffect(
new ChooseAndExertCharactersEffect(action, playerId, 1, 1, 2, CardType.COMPANION));
return Collections.singletonList(action);
}
return null;
}
}

View File

@@ -1,42 +0,0 @@
package com.gempukku.lotro.cards.set15.site;
import com.gempukku.lotro.common.CardType;
import com.gempukku.lotro.common.Keyword;
import com.gempukku.lotro.common.Zone;
import com.gempukku.lotro.filters.Filters;
import com.gempukku.lotro.game.PhysicalCard;
import com.gempukku.lotro.game.StringWhileInZoneData;
import com.gempukku.lotro.game.state.LotroGame;
import com.gempukku.lotro.logic.GameUtils;
import com.gempukku.lotro.logic.actions.RequiredTriggerAction;
import com.gempukku.lotro.logic.cardtype.AbstractShadowsSite;
import com.gempukku.lotro.logic.modifiers.CantReplaceSiteModifier;
import com.gempukku.lotro.logic.timing.EffectResult;
import java.util.List;
/**
* Set: The Hunters
* Twilight Cost: 3
* Type: Site
* Game Text: Battleground. Mountain. Underground. Until the end of the game, sites in this region cannot be replaced.
*/
public class Card15_193 extends AbstractShadowsSite {
public Card15_193() {
super("Mount Doom", 3, Direction.LEFT);
addKeyword(Keyword.BATTLEGROUND);
addKeyword(Keyword.MOUNTAIN);
addKeyword(Keyword.UNDERGROUND);
}
@Override
public List<RequiredTriggerAction> getRequiredAfterTriggers(LotroGame game, EffectResult effectResult, PhysicalCard self) {
if (self.getWhileInZoneData() == null) {
int region = GameUtils.getRegion(self.getSiteNumber());
self.setWhileInZoneData(new StringWhileInZoneData(null));
game.getModifiersEnvironment().addAlwaysOnModifier(
new CantReplaceSiteModifier(self, null, null, Filters.and(CardType.SITE, Zone.ADVENTURE_PATH, Filters.region(region))));
}
return null;
}
}

View File

@@ -1,30 +0,0 @@
package com.gempukku.lotro.cards.set15.site;
import com.gempukku.lotro.common.Keyword;
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.AbstractShadowsSite;
import com.gempukku.lotro.logic.modifiers.Modifier;
import com.gempukku.lotro.logic.modifiers.StrengthModifier;
import java.util.Collections;
import java.util.List;
/**
* Set: The Hunters
* Twilight Cost: 2
* Type: Site
* Game Text: Plains. Each hunter character is strength +1.
*/
public class Card15_194 extends AbstractShadowsSite {
public Card15_194() {
super("Westfold Village", 2, Direction.LEFT);
addKeyword(Keyword.PLAINS);
}
@Override
public List<? extends Modifier> getInPlayModifiers(LotroGame game, PhysicalCard self) {
return Collections.singletonList(new StrengthModifier(self, Filters.and(Filters.character, Keyword.HUNTER), 1));
}
}

View File

@@ -23,6 +23,14 @@
direction: Left
keywords: River
effects: [
{
type: modifier
modifier: {
type: modifyArcheryTotal
side: shadow
amount: -3
}
}
]
gametext: <b>River</b>. The fellowship archery total is -3.
lore: ""
@@ -58,6 +66,21 @@
direction: Left
keywords: Underground
effects: [
{
type: modifier
modifier: {
type: modifyCost
requires: {
type: not
requires: {
type: playedCardThisPhase
filter: hunter,minion
}
}
filter: hunter,minion
amount: -2
}
}
]
gametext: <b>Underground</b>. The twilight cost of the first hunter minion played each Shadow phase is -2.
lore: ""
@@ -92,6 +115,30 @@
block: Shadows
direction: Right
effects: [
{
type: trigger
trigger: {
type: movesTo
filter: self
}
effect: {
type: addThreats
amount: {
type: forEachYouCanSpot
filter: companion
over: 4
multiplier: {
type: condition
condition: {
type: canSpot
filter: hunter,minion
}
true: 2
false: 1
}
}
}
}
]
gametext: When the Fellowship moves to this site, add a threat (or 2 if you can spot a hunter minion) for each companion over 4.
lore: ""
@@ -126,6 +173,24 @@
block: Shadows
direction: Right
effects: [
{
type: trigger
optional: true
player: free people
trigger: {
type: startOfPhase
phase: fellowship
}
cost: {
type: exert
filter: choose(hunter,companion)
count: 2
}
effect: {
type: playCardFromDrawDeck
filter: choose(hunter,companion)
}
}
]
gametext: At the start of the fellowship phase, you may exert two hunter companions to play a hunter companion from your draw deck.
lore: ""
@@ -161,6 +226,19 @@
direction: Left
keywords: Battleground
effects: [
{
type: trigger
trigger: {
type: movesTo
filter: self
}
effect: {
type: addTwilight
amount: {
type: forEachCulture
}
}
}
]
gametext: <b>Battleground</b>. Each time the fellowship moves to this site, add (1) for each culture you can spot.
lore: ""
@@ -196,6 +274,20 @@
direction: Right
keywords: Battleground
effects: [
{
type: trigger
trigger: {
type: transferred
filter: follower
to: character
}
effect: {
type: exert
player: shadow
filter: choose(companion)
times: 2
}
}
]
gametext: <b>Battleground</b>. Each time a follower is transferred to a character, the first Shadow player may exert a companion twice.
lore: ""
@@ -235,6 +327,38 @@
Underground
]
effects: [
{
type: trigger
trigger: {
type: constantlyCheck
}
requires: {
type: not
requires: {
type: hasInZoneData
filter: self
}
}
effect: [
{
type: memorizeValue
memory: used
value: yes
}
{
type: storeWhileInZone
memory: used
}
{
type: addModifier
modifier: {
type: cantReplaceSite
filter: inSameRegion
}
until: endOfGame
}
]
}
]
gametext: <b>Battleground</b>. <b>Mountain</b>. <b>Underground</b>. Until the end of the game, sites in this region cannot be replaced.
lore: ""
@@ -270,6 +394,14 @@
direction: Left
keywords: Plains
effects: [
{
type: modifier
modifier: {
type: modifyStrength
filter: hunter,character
amount: 1
}
}
]
gametext: <b>Plains</b>. Each hunter character is strength +1.
lore: ""