diff --git a/Mage.Sets/src/mage/cards/i/IncubationIncongruity.java b/Mage.Sets/src/mage/cards/i/IncubationIncongruity.java new file mode 100644 index 0000000000..9e8278b989 --- /dev/null +++ b/Mage.Sets/src/mage/cards/i/IncubationIncongruity.java @@ -0,0 +1,81 @@ +package mage.cards.i; + +import mage.abilities.Ability; +import mage.abilities.dynamicvalue.common.StaticValue; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.ExileTargetEffect; +import mage.abilities.effects.common.LookLibraryAndPickControllerEffect; +import mage.cards.CardSetInfo; +import mage.cards.SplitCard; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.SpellAbilityType; +import mage.constants.Zone; +import mage.filter.StaticFilters; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.game.permanent.token.FrogLizardToken; +import mage.target.common.TargetCreaturePermanent; + +import java.util.UUID; + +/** + * @author TheElk801 + */ +public final class IncubationIncongruity extends SplitCard { + + public IncubationIncongruity(UUID ownerId, CardSetInfo setInfo) { + super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, new CardType[]{CardType.INSTANT}, "{G/U}", "{1}{G}{U}", SpellAbilityType.SPLIT); + + // Incubation + // Look at the top five cards of your library. You may reveal a creature card from among them and put it into your hand. Put the rest on the bottom of your library in a random order. + this.getLeftHalfCard().getSpellAbility().addEffect(new LookLibraryAndPickControllerEffect( + new StaticValue(5), false, + new StaticValue(1), StaticFilters.FILTER_CARD_CREATURE_A, + Zone.LIBRARY, false, true, false, + Zone.HAND, false, false, false + )); + + // Incongruity + // Exile target creature. That creature's controller creates a 3/3 green Frog Lizard creature token. + this.getRightHalfCard().getSpellAbility().addTarget(new TargetCreaturePermanent()); + this.getRightHalfCard().getSpellAbility().addEffect(new ExileTargetEffect()); + this.getRightHalfCard().getSpellAbility().addEffect(new IncongruityEffect()); + } + + private IncubationIncongruity(final IncubationIncongruity card) { + super(card); + } + + @Override + public IncubationIncongruity copy() { + return new IncubationIncongruity(this); + } +} + +class IncongruityEffect extends OneShotEffect { + + public IncongruityEffect() { + super(Outcome.PutCreatureInPlay); + staticText = "That creature's controller creates a 3/3 green Frog Lizard creature token"; + } + + public IncongruityEffect(final IncongruityEffect effect) { + super(effect); + } + + @Override + public IncongruityEffect copy() { + return new IncongruityEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent permanent = game.getPermanentOrLKIBattlefield(targetPointer.getFirst(game, source)); + if (permanent != null) { + FrogLizardToken token = new FrogLizardToken(); + token.putOntoBattlefield(1, game, source.getSourceId(), permanent.getControllerId()); + } + return true; + } +} diff --git a/Mage.Sets/src/mage/cards/r/RapidHybridization.java b/Mage.Sets/src/mage/cards/r/RapidHybridization.java index c86b017c12..5c157eeb92 100644 --- a/Mage.Sets/src/mage/cards/r/RapidHybridization.java +++ b/Mage.Sets/src/mage/cards/r/RapidHybridization.java @@ -11,7 +11,7 @@ import mage.constants.CardType; import mage.constants.Outcome; import mage.game.Game; import mage.game.permanent.Permanent; -import mage.game.permanent.token.RapidHybridizationToken; +import mage.game.permanent.token.FrogLizardToken; import mage.target.common.TargetCreaturePermanent; /** @@ -59,7 +59,7 @@ class RapidHybridizationEffect extends OneShotEffect { public boolean apply(Game game, Ability source) { Permanent permanent = game.getPermanentOrLKIBattlefield(targetPointer.getFirst(game, source)); if (permanent != null) { - RapidHybridizationToken token = new RapidHybridizationToken(); + FrogLizardToken token = new FrogLizardToken(); token.putOntoBattlefield(1, game, source.getSourceId(), permanent.getControllerId()); } return true; diff --git a/Mage.Sets/src/mage/sets/RavnicaAllegiance.java b/Mage.Sets/src/mage/sets/RavnicaAllegiance.java index fbadfbd759..50e46da266 100644 --- a/Mage.Sets/src/mage/sets/RavnicaAllegiance.java +++ b/Mage.Sets/src/mage/sets/RavnicaAllegiance.java @@ -39,6 +39,7 @@ public final class RavnicaAllegiance extends ExpansionSet { cards.add(new SetCardInfo("Growth Spiral", 178, Rarity.COMMON, mage.cards.g.GrowthSpiral.class)); cards.add(new SetCardInfo("Gruul Spellbreaker", 179, Rarity.RARE, mage.cards.g.GruulSpellbreaker.class)); cards.add(new SetCardInfo("Imperious Oligarch", 184, Rarity.COMMON, mage.cards.i.ImperiousOligarch.class)); + cards.add(new SetCardInfo("Incubation // Incongruity", 226, Rarity.UNCOMMON, mage.cards.i.IncubationIncongruity.class)); cards.add(new SetCardInfo("Light Up the Stage", 107, Rarity.UNCOMMON, mage.cards.l.LightUpTheStage.class)); cards.add(new SetCardInfo("Mortify", 192, Rarity.UNCOMMON, mage.cards.m.Mortify.class)); cards.add(new SetCardInfo("Rafter Demon", 196, Rarity.COMMON, mage.cards.r.RafterDemon.class)); diff --git a/Mage/src/main/java/mage/game/permanent/token/RapidHybridizationToken.java b/Mage/src/main/java/mage/game/permanent/token/FrogLizardToken.java similarity index 66% rename from Mage/src/main/java/mage/game/permanent/token/RapidHybridizationToken.java rename to Mage/src/main/java/mage/game/permanent/token/FrogLizardToken.java index 0f3b2c7dd9..bf46efa927 100644 --- a/Mage/src/main/java/mage/game/permanent/token/RapidHybridizationToken.java +++ b/Mage/src/main/java/mage/game/permanent/token/FrogLizardToken.java @@ -9,9 +9,9 @@ import mage.MageInt; * * @author spjspj */ -public final class RapidHybridizationToken extends TokenImpl { +public final class FrogLizardToken extends TokenImpl { - public RapidHybridizationToken() { + public FrogLizardToken() { super("Frog Lizard", "3/3 green Frog Lizard creature token"); this.setOriginalExpansionSetCode("GTC"); cardType.add(CardType.CREATURE); @@ -25,11 +25,11 @@ public final class RapidHybridizationToken extends TokenImpl { toughness = new MageInt(3); } - public RapidHybridizationToken(final RapidHybridizationToken token) { + public FrogLizardToken(final FrogLizardToken token) { super(token); } - public RapidHybridizationToken copy() { - return new RapidHybridizationToken(this); + public FrogLizardToken copy() { + return new FrogLizardToken(this); } }