diff --git a/Mage.Sets/src/mage/cards/i/IngaRuneEyes.java b/Mage.Sets/src/mage/cards/i/IngaRuneEyes.java new file mode 100644 index 00000000000..d58aa842d00 --- /dev/null +++ b/Mage.Sets/src/mage/cards/i/IngaRuneEyes.java @@ -0,0 +1,66 @@ +package mage.cards.i; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.DiesSourceTriggeredAbility; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.condition.Condition; +import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.keyword.ScryEffect; +import mage.constants.SubType; +import mage.constants.SuperType; +import mage.cards.CardImpl; +import mage.cards.CardSetInfo; +import mage.constants.CardType; +import mage.game.Game; +import mage.watchers.common.CreaturesDiedWatcher; + +/** + * + * @author weirddan455 + */ +public final class IngaRuneEyes extends CardImpl { + + public IngaRuneEyes(UUID ownerId, CardSetInfo setInfo) { + super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{3}{U}"); + + this.addSuperType(SuperType.LEGENDARY); + this.subtype.add(SubType.HUMAN); + this.subtype.add(SubType.WIZARD); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // When Inga Rune-Eyes enters the battlefield, scry 3. + this.addAbility(new EntersBattlefieldTriggeredAbility(new ScryEffect(3))); + + // When Inga Rune-Eyes dies, draw three cards if three or more creatures died this turn. + this.addAbility(new DiesSourceTriggeredAbility(new ConditionalOneShotEffect( + new DrawCardSourceControllerEffect(3), IngaRuneEyesCondition.instance + ).setText("draw three cards if three or more creatures died this turn")), new CreaturesDiedWatcher()); + } + + private IngaRuneEyes(final IngaRuneEyes card) { + super(card); + } + + @Override + public IngaRuneEyes copy() { + return new IngaRuneEyes(this); + } +} + +enum IngaRuneEyesCondition implements Condition { + + instance; + + @Override + public boolean apply (Game game, Ability source) { + CreaturesDiedWatcher watcher = game.getState().getWatcher(CreaturesDiedWatcher.class); + if (watcher != null) { + return watcher.getAmountOfCreaturesDiedThisTurn() > 2; + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/Kaldheim.java b/Mage.Sets/src/mage/sets/Kaldheim.java index 63a59252325..8da2b57e57d 100644 --- a/Mage.Sets/src/mage/sets/Kaldheim.java +++ b/Mage.Sets/src/mage/sets/Kaldheim.java @@ -66,6 +66,7 @@ public final class Kaldheim extends ExpansionSet { cards.add(new SetCardInfo("Hengegate Pathway", 260, Rarity.RARE, mage.cards.h.HengegatePathway.class)); cards.add(new SetCardInfo("Highland Forest", 261, Rarity.COMMON, mage.cards.h.HighlandForest.class)); cards.add(new SetCardInfo("Ice Tunnel", 262, Rarity.COMMON, mage.cards.i.IceTunnel.class)); + cards.add(new SetCardInfo("Inga Rune-Eyes", 64, Rarity.UNCOMMON, mage.cards.i.IngaRuneEyes.class)); cards.add(new SetCardInfo("Invasion of the Giants", 215, Rarity.UNCOMMON, mage.cards.i.InvasionOfTheGiants.class)); cards.add(new SetCardInfo("Kaya the Inexorable", 218, Rarity.MYTHIC, mage.cards.k.KayaTheInexorable.class)); cards.add(new SetCardInfo("Magda, Brazen Outlaw", 142, Rarity.RARE, mage.cards.m.MagdaBrazenOutlaw.class));