From 561a2df2d5fd3da59beb5d1e0a5c377108035bc0 Mon Sep 17 00:00:00 2001 From: Evan Kranzler Date: Thu, 1 Apr 2021 20:58:38 -0400 Subject: [PATCH] fixed an error --- Mage.Sets/src/mage/cards/n/NightmaresThirst.java | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/Mage.Sets/src/mage/cards/n/NightmaresThirst.java b/Mage.Sets/src/mage/cards/n/NightmaresThirst.java index 22f54e539c4..f72d9c44d20 100644 --- a/Mage.Sets/src/mage/cards/n/NightmaresThirst.java +++ b/Mage.Sets/src/mage/cards/n/NightmaresThirst.java @@ -1,11 +1,10 @@ package mage.cards.n; -import java.util.UUID; import mage.abilities.dynamicvalue.DynamicValue; import mage.abilities.dynamicvalue.MultipliedValue; +import mage.abilities.dynamicvalue.common.ControllerGotLifeCount; import mage.abilities.effects.common.GainLifeEffect; import mage.abilities.effects.common.continuous.BoostTargetEffect; -import mage.abilities.dynamicvalue.common.ControllerGotLifeCount; import mage.cards.CardImpl; import mage.cards.CardSetInfo; import mage.constants.CardType; @@ -13,23 +12,26 @@ import mage.constants.Duration; import mage.target.common.TargetCreaturePermanent; import mage.watchers.common.PlayerGainedLifeWatcher; +import java.util.UUID; + /** - * * @author TheElk801 */ public final class NightmaresThirst extends CardImpl { + private static final DynamicValue xValue = new MultipliedValue(ControllerGotLifeCount.instance, -1); + public NightmaresThirst(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{B}"); // You gain 1 life. Target creature gets -X/-X until end of turn, where X is the amount of life you gained this turn. this.getSpellAbility().addEffect(new GainLifeEffect(1)); - DynamicValue xValue = new MultipliedValue(ControllerGotLifeCount.getInstance(), -1); this.getSpellAbility().addEffect(new BoostTargetEffect( xValue, xValue, Duration.EndOfTurn, true ).setText("Target creature gets -X/-X until end of turn, where X is the amount of life you gained this turn.")); this.getSpellAbility().addTarget(new TargetCreaturePermanent()); this.getSpellAbility().addWatcher(new PlayerGainedLifeWatcher()); + this.getSpellAbility().addHint(ControllerGotLifeCount.getHint()); } private NightmaresThirst(final NightmaresThirst card) {