From 40e8b32d59dbe24d72444b6a2cf3861733da6126 Mon Sep 17 00:00:00 2001 From: "marcins78@gmail.com" Date: Sun, 4 Dec 2011 14:21:11 +0000 Subject: [PATCH] - The One Ring(s) no longer prevent the wound, so will work on Steward's Tomb. --- .../cards/effects/NegateWoundEffect.java | 29 +++++++++++++++++++ .../gempukku/lotro/cards/set1/Card1_001.java | 6 ++-- .../gempukku/lotro/cards/set1/Card1_002.java | 6 ++-- .../lotro/cards/set11/Card11_001.java | 6 ++-- .../gempukku/lotro/cards/set4/Card4_001.java | 4 +-- .../gempukku/lotro/cards/set7/Card7_002.java | 4 +-- .../gempukku/lotro/cards/set9/Card9_001.java | 4 +-- .../logic/effects/WoundCharactersEffect.java | 4 +++ .../src/main/webapp/includes/changeLog.html | 3 ++ 9 files changed, 51 insertions(+), 15 deletions(-) create mode 100644 gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/effects/NegateWoundEffect.java diff --git a/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/effects/NegateWoundEffect.java b/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/effects/NegateWoundEffect.java new file mode 100644 index 000000000..ad2ce69be --- /dev/null +++ b/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/effects/NegateWoundEffect.java @@ -0,0 +1,29 @@ +package com.gempukku.lotro.cards.effects; + +import com.gempukku.lotro.game.PhysicalCard; +import com.gempukku.lotro.game.state.LotroGame; +import com.gempukku.lotro.logic.effects.WoundCharactersEffect; +import com.gempukku.lotro.logic.timing.UnrespondableEffect; + +import java.util.Collection; +import java.util.Collections; + +public class NegateWoundEffect extends UnrespondableEffect { + private WoundCharactersEffect _effect; + private Collection _cards; + + public NegateWoundEffect(WoundCharactersEffect effect, PhysicalCard card) { + this(effect, Collections.singleton(card)); + } + + public NegateWoundEffect(WoundCharactersEffect effect, Collection cards) { + _effect = effect; + _cards = cards; + } + + @Override + protected void doPlayEffect(LotroGame game) { + for (PhysicalCard card : _cards) + _effect.negateWound(game, card); + } +} diff --git a/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set1/Card1_001.java b/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set1/Card1_001.java index 6bb295063..826c2fb84 100644 --- a/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set1/Card1_001.java +++ b/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set1/Card1_001.java @@ -3,7 +3,7 @@ package com.gempukku.lotro.cards.set1; import com.gempukku.lotro.cards.AbstractAttachable; import com.gempukku.lotro.cards.TriggerConditions; import com.gempukku.lotro.cards.effects.AddBurdenEffect; -import com.gempukku.lotro.cards.effects.PreventCardEffect; +import com.gempukku.lotro.cards.effects.NegateWoundEffect; import com.gempukku.lotro.cards.effects.PutOnTheOneRingEffect; import com.gempukku.lotro.cards.effects.TakeOffTheOneRingEffect; import com.gempukku.lotro.cards.modifiers.VitalityModifier; @@ -64,7 +64,7 @@ public class Card1_001 extends AbstractAttachable { List actions = new LinkedList(); ActivateCardAction action = new ActivateCardAction(self); - action.appendEffect(new PreventCardEffect(woundEffect, self.getAttachedTo())); + action.appendEffect(new NegateWoundEffect(woundEffect, self.getAttachedTo())); action.appendEffect(new AddBurdenEffect(self, 2)); action.appendEffect(new PutOnTheOneRingEffect()); @@ -82,7 +82,7 @@ public class Card1_001 extends AbstractAttachable { WoundCharactersEffect woundEffect = (WoundCharactersEffect) effect; if (woundEffect.getAffectedCardsMinusPrevented(game).contains(self.getAttachedTo())) { RequiredTriggerAction action = new RequiredTriggerAction(self); - action.appendEffect(new PreventCardEffect(woundEffect, self.getAttachedTo())); + action.appendEffect(new NegateWoundEffect(woundEffect, self.getAttachedTo())); action.appendEffect(new AddBurdenEffect(self, 2)); return Collections.singletonList(action); } diff --git a/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set1/Card1_002.java b/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set1/Card1_002.java index 012d69792..e7e4c3f78 100644 --- a/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set1/Card1_002.java +++ b/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set1/Card1_002.java @@ -3,7 +3,7 @@ package com.gempukku.lotro.cards.set1; import com.gempukku.lotro.cards.AbstractAttachable; import com.gempukku.lotro.cards.TriggerConditions; import com.gempukku.lotro.cards.effects.AddBurdenEffect; -import com.gempukku.lotro.cards.effects.PreventCardEffect; +import com.gempukku.lotro.cards.effects.NegateWoundEffect; import com.gempukku.lotro.cards.effects.PutOnTheOneRingEffect; import com.gempukku.lotro.cards.effects.TakeOffTheOneRingEffect; import com.gempukku.lotro.common.CardType; @@ -64,7 +64,7 @@ public class Card1_002 extends AbstractAttachable { List actions = new LinkedList(); ActivateCardAction action = new ActivateCardAction(self); - action.appendEffect(new PreventCardEffect(woundEffect, self.getAttachedTo())); + action.appendEffect(new NegateWoundEffect(woundEffect, self.getAttachedTo())); action.appendEffect(new AddBurdenEffect(self, 1)); action.appendEffect(new PutOnTheOneRingEffect()); @@ -84,7 +84,7 @@ public class Card1_002 extends AbstractAttachable { if (woundEffect.getAffectedCardsMinusPrevented(game).contains(self.getAttachedTo())) { List actions = new LinkedList(); RequiredTriggerAction action = new RequiredTriggerAction(self); - action.appendEffect(new PreventCardEffect(woundEffect, self.getAttachedTo())); + action.appendEffect(new NegateWoundEffect(woundEffect, self.getAttachedTo())); action.appendEffect(new AddBurdenEffect(self, 1)); return actions; } diff --git a/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set11/Card11_001.java b/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set11/Card11_001.java index d10b40a20..9a4543b83 100644 --- a/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set11/Card11_001.java +++ b/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set11/Card11_001.java @@ -3,7 +3,7 @@ package com.gempukku.lotro.cards.set11; import com.gempukku.lotro.cards.AbstractAttachable; import com.gempukku.lotro.cards.TriggerConditions; import com.gempukku.lotro.cards.effects.AddBurdenEffect; -import com.gempukku.lotro.cards.effects.PreventCardEffect; +import com.gempukku.lotro.cards.effects.NegateWoundEffect; import com.gempukku.lotro.cards.effects.PutOnTheOneRingEffect; import com.gempukku.lotro.cards.effects.TakeOffTheOneRingEffect; import com.gempukku.lotro.cards.modifiers.ResistanceModifier; @@ -63,7 +63,7 @@ public class Card11_001 extends AbstractAttachable { List actions = new LinkedList(); ActivateCardAction action = new ActivateCardAction(self); - action.appendEffect(new PreventCardEffect(woundEffect, self.getAttachedTo())); + action.appendEffect(new NegateWoundEffect(woundEffect, self.getAttachedTo())); action.appendEffect(new AddBurdenEffect(self, 1)); action.appendEffect(new PutOnTheOneRingEffect()); @@ -83,7 +83,7 @@ public class Card11_001 extends AbstractAttachable { if (woundEffect.getAffectedCardsMinusPrevented(game).contains(self.getAttachedTo())) { List actions = new LinkedList(); RequiredTriggerAction action = new RequiredTriggerAction(self); - action.appendEffect(new PreventCardEffect(woundEffect, self.getAttachedTo())); + action.appendEffect(new NegateWoundEffect(woundEffect, self.getAttachedTo())); action.appendEffect(new AddBurdenEffect(self, 1)); return actions; } diff --git a/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set4/Card4_001.java b/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set4/Card4_001.java index 132e7862a..db4bfebb9 100644 --- a/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set4/Card4_001.java +++ b/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set4/Card4_001.java @@ -4,7 +4,7 @@ import com.gempukku.lotro.cards.AbstractAttachable; import com.gempukku.lotro.cards.PlayConditions; import com.gempukku.lotro.cards.TriggerConditions; import com.gempukku.lotro.cards.effects.AddBurdenEffect; -import com.gempukku.lotro.cards.effects.PreventCardEffect; +import com.gempukku.lotro.cards.effects.NegateWoundEffect; import com.gempukku.lotro.cards.effects.PutOnTheOneRingEffect; import com.gempukku.lotro.cards.effects.TakeOffTheOneRingEffect; import com.gempukku.lotro.cards.modifiers.VitalityModifier; @@ -84,7 +84,7 @@ public class Card4_001 extends AbstractAttachable { && !game.getModifiersQuerying().hasFlagActive(game.getGameState(), ModifierFlag.RING_TEXT_INACTIVE)) { WoundCharactersEffect woundEffect = (WoundCharactersEffect) effect; RequiredTriggerAction action = new RequiredTriggerAction(self); - action.appendEffect(new PreventCardEffect(woundEffect, self.getAttachedTo())); + action.appendEffect(new NegateWoundEffect(woundEffect, self.getAttachedTo())); action.appendEffect(new AddBurdenEffect(self, 1)); return Collections.singletonList(action); } diff --git a/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set7/Card7_002.java b/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set7/Card7_002.java index 6aab33aa5..54ff13738 100644 --- a/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set7/Card7_002.java +++ b/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set7/Card7_002.java @@ -4,7 +4,7 @@ import com.gempukku.lotro.cards.AbstractAttachable; import com.gempukku.lotro.cards.PlayConditions; import com.gempukku.lotro.cards.TriggerConditions; import com.gempukku.lotro.cards.effects.AddBurdenEffect; -import com.gempukku.lotro.cards.effects.PreventCardEffect; +import com.gempukku.lotro.cards.effects.NegateWoundEffect; import com.gempukku.lotro.cards.effects.PutOnTheOneRingEffect; import com.gempukku.lotro.cards.effects.TakeOffTheOneRingEffect; import com.gempukku.lotro.common.CardType; @@ -77,7 +77,7 @@ public class Card7_002 extends AbstractAttachable { && !game.getModifiersQuerying().hasFlagActive(game.getGameState(), ModifierFlag.RING_TEXT_INACTIVE)) { WoundCharactersEffect woundEffect = (WoundCharactersEffect) effect; RequiredTriggerAction action = new RequiredTriggerAction(self); - action.appendEffect(new PreventCardEffect(woundEffect, self.getAttachedTo())); + action.appendEffect(new NegateWoundEffect(woundEffect, self.getAttachedTo())); action.appendEffect(new AddBurdenEffect(self, 1)); return Collections.singletonList(action); } diff --git a/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set9/Card9_001.java b/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set9/Card9_001.java index 2f76d12f1..329d9ca97 100644 --- a/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set9/Card9_001.java +++ b/gemp-lotr/gemp-lotr-cards/src/main/java/com/gempukku/lotro/cards/set9/Card9_001.java @@ -4,7 +4,7 @@ import com.gempukku.lotro.cards.AbstractAttachable; import com.gempukku.lotro.cards.PlayConditions; import com.gempukku.lotro.cards.TriggerConditions; import com.gempukku.lotro.cards.effects.AddBurdenEffect; -import com.gempukku.lotro.cards.effects.PreventCardEffect; +import com.gempukku.lotro.cards.effects.NegateWoundEffect; import com.gempukku.lotro.cards.effects.PutOnTheOneRingEffect; import com.gempukku.lotro.cards.effects.TakeOffTheOneRingEffect; import com.gempukku.lotro.cards.effects.choose.ChooseAndExertCharactersEffect; @@ -91,7 +91,7 @@ public class Card9_001 extends AbstractAttachable { WoundCharactersEffect woundEffect = (WoundCharactersEffect) effect; if (woundEffect.getAffectedCardsMinusPrevented(game).contains(self.getAttachedTo())) { RequiredTriggerAction action = new RequiredTriggerAction(self); - action.appendEffect(new PreventCardEffect(woundEffect, self.getAttachedTo())); + action.appendEffect(new NegateWoundEffect(woundEffect, self.getAttachedTo())); action.appendEffect(new AddBurdenEffect(self, 1)); return Collections.singletonList(action); } diff --git a/gemp-lotr/gemp-lotr-logic/src/main/java/com/gempukku/lotro/logic/effects/WoundCharactersEffect.java b/gemp-lotr/gemp-lotr-logic/src/main/java/com/gempukku/lotro/logic/effects/WoundCharactersEffect.java index 03b6f673a..b5a40c8b7 100644 --- a/gemp-lotr/gemp-lotr-logic/src/main/java/com/gempukku/lotro/logic/effects/WoundCharactersEffect.java +++ b/gemp-lotr/gemp-lotr-logic/src/main/java/com/gempukku/lotro/logic/effects/WoundCharactersEffect.java @@ -87,4 +87,8 @@ public class WoundCharactersEffect extends AbstractPreventableCardEffect { if (!game.getModifiersQuerying().hasFlagActive(game.getGameState(), ModifierFlag.CANT_PREVENT_WOUNDS)) super.preventEffect(game, card); } + + public void negateWound(LotroGame game, PhysicalCard card) { + super.preventEffect(game, card); + } } diff --git a/gemp-lotr/gemp-lotr-web/src/main/webapp/includes/changeLog.html b/gemp-lotr/gemp-lotr-web/src/main/webapp/includes/changeLog.html index cf2744235..43b953cb9 100644 --- a/gemp-lotr/gemp-lotr-web/src/main/webapp/includes/changeLog.html +++ b/gemp-lotr/gemp-lotr-web/src/main/webapp/includes/changeLog.html @@ -1,4 +1,7 @@
+4 Dec. 2011
+- The One Ring(s) no longer prevent the wound, so will work on Steward's Tomb.
+
 3 Dec. 2011
 - "Fifth Level" can now be transferred to a minion.
 - "Thundering Host" now works only on mounted characters.