diff --git a/Mage.Sets/src/mage/cards/k/KrangMasterMind.java b/Mage.Sets/src/mage/cards/k/KrangMasterMind.java new file mode 100644 index 00000000000..337b666365c --- /dev/null +++ b/Mage.Sets/src/mage/cards/k/KrangMasterMind.java @@ -0,0 +1,67 @@ +package mage.cards.k; + +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.condition.Condition; +import mage.abilities.condition.common.CardsInHandCondition; +import mage.abilities.dynamicvalue.DynamicValue; +import mage.abilities.dynamicvalue.common.PermanentsOnBattlefieldCount; +import mage.abilities.dynamicvalue.common.StaticValue; +import mage.abilities.effects.common.DrawCardsEqualToDifferenceEffect; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.abilities.keyword.AffinityForArtifactsAbility; +import mage.cards.CardImpl; +import mage.cards.CardSetInfo; +import mage.constants.*; +import mage.filter.FilterPermanent; +import mage.filter.common.FilterControlledArtifactPermanent; +import mage.filter.predicate.mageobject.AnotherPredicate; + +import java.util.UUID; + +/** + * @author TheElk801 + */ +public final class KrangMasterMind extends CardImpl { + + private static final Condition condition = new CardsInHandCondition(ComparisonType.FEWER_THAN, 4); + private static final FilterPermanent filter = new FilterControlledArtifactPermanent("other artifact you control"); + + static { + filter.add(AnotherPredicate.instance); + } + + private static final DynamicValue xValue = new PermanentsOnBattlefieldCount(filter); + + public KrangMasterMind(UUID ownerId, CardSetInfo setInfo) { + super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{6}{U}{U}"); + + this.supertype.add(SuperType.LEGENDARY); + this.subtype.add(SubType.UTROM); + this.subtype.add(SubType.WARRIOR); + this.power = new MageInt(1); + this.toughness = new MageInt(4); + + // Affinity for artifacts + this.addAbility(new AffinityForArtifactsAbility()); + + // When Krang enters, if you have fewer than four cards in hand, draw cards equal to the difference. + this.addAbility(new EntersBattlefieldTriggeredAbility(new DrawCardsEqualToDifferenceEffect(4)) + .withInterveningIf(condition)); + + // Krang gets +1/+0 for each other artifact you control. + this.addAbility(new SimpleStaticAbility(new BoostSourceEffect( + xValue, StaticValue.get(0), Duration.WhileOnBattlefield + ))); + } + + private KrangMasterMind(final KrangMasterMind card) { + super(card); + } + + @Override + public KrangMasterMind copy() { + return new KrangMasterMind(this); + } +} diff --git a/Mage.Sets/src/mage/sets/TeenageMutantNinjaTurtles.java b/Mage.Sets/src/mage/sets/TeenageMutantNinjaTurtles.java index 1c59fc4c485..7f0fc9a44ae 100644 --- a/Mage.Sets/src/mage/sets/TeenageMutantNinjaTurtles.java +++ b/Mage.Sets/src/mage/sets/TeenageMutantNinjaTurtles.java @@ -26,6 +26,7 @@ public final class TeenageMutantNinjaTurtles extends ExpansionSet { cards.add(new SetCardInfo("Forest", 314, Rarity.LAND, mage.cards.basiclands.Forest.class, FULL_ART_BFZ_VARIOUS)); cards.add(new SetCardInfo("Island", 254, Rarity.LAND, mage.cards.basiclands.Island.class, FULL_ART_BFZ_VARIOUS)); cards.add(new SetCardInfo("Island", 311, Rarity.LAND, mage.cards.basiclands.Island.class, FULL_ART_BFZ_VARIOUS)); + cards.add(new SetCardInfo("Krang, Master Mind", 43, Rarity.RARE, mage.cards.k.KrangMasterMind.class)); cards.add(new SetCardInfo("Mountain", 256, Rarity.LAND, mage.cards.basiclands.Mountain.class, FULL_ART_BFZ_VARIOUS)); cards.add(new SetCardInfo("Mountain", 313, Rarity.LAND, mage.cards.basiclands.Mountain.class, FULL_ART_BFZ_VARIOUS)); cards.add(new SetCardInfo("Plains", 253, Rarity.LAND, mage.cards.basiclands.Plains.class, FULL_ART_BFZ_VARIOUS)); diff --git a/Mage/src/main/java/mage/constants/SubType.java b/Mage/src/main/java/mage/constants/SubType.java index 50f81cc87e8..4a2c79c94ec 100644 --- a/Mage/src/main/java/mage/constants/SubType.java +++ b/Mage/src/main/java/mage/constants/SubType.java @@ -431,6 +431,7 @@ public enum SubType { // U UGNAUGHT("Ugnaught", SubTypeSet.CreatureType, true), UNICORN("Unicorn", SubTypeSet.CreatureType), + UTROM("Utrom", SubTypeSet.CreatureType), // V VAMPIRE("Vampire", SubTypeSet.CreatureType), VARMINT("Varmint", SubTypeSet.CreatureType),