diff --git a/Mage.Sets/src/mage/sets/dragonsmaze/BloodScrivener.java b/Mage.Sets/src/mage/sets/dragonsmaze/BloodScrivener.java new file mode 100644 index 0000000000..77f3bdf2e4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/dragonsmaze/BloodScrivener.java @@ -0,0 +1,121 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ + +package mage.sets.dragonsmaze; + +import java.util.UUID; +import mage.Constants.CardType; +import mage.Constants.Duration; +import mage.Constants.Outcome; +import mage.Constants.Rarity; +import mage.Constants.Zone; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.ReplacementEffectImpl; +import mage.cards.CardImpl; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.events.GameEvent.EventType; +import mage.players.Player; + +/** + * + * @author LevelX2 + */ + + +public class BloodScrivener extends CardImpl { + + public BloodScrivener (UUID ownerId) { + super(ownerId, 22, "Blood Scrivener", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{B}"); + this.expansionSetCode = "DGM"; + this.subtype.add("Zombie"); + this.subtype.add("Wizard"); + this.color.setBlack(true); + this.power = new MageInt(2); + this.toughness = new MageInt(1); + + // If you would draw a card while you have no cards in hand, instead draw two cards and lose 1 life. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BloodScrivenerReplacementEffect())); + + } + + public BloodScrivener (final BloodScrivener card) { + super(card); + } + + @Override + public BloodScrivener copy() { + return new BloodScrivener(this); + } + +} + +class BloodScrivenerReplacementEffect extends ReplacementEffectImpl { + + public BloodScrivenerReplacementEffect() { + super(Duration.WhileOnBattlefield, Outcome.Benefit); + staticText = "If you would draw a card while you have no cards in hand, instead draw two cards and lose 1 life"; + } + + public BloodScrivenerReplacementEffect(final BloodScrivenerReplacementEffect effect) { + super(effect); + } + + @Override + public BloodScrivenerReplacementEffect copy() { + return new BloodScrivenerReplacementEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + return true; + } + + @Override + public boolean replaceEvent(GameEvent event, Ability source, Game game) { + Player player = game.getPlayer(event.getPlayerId()); + if (player != null) { + player.drawCards(2, game, event.getAppliedEffects()); + player.loseLife(1, game); + } + return true; + } + + @Override + public boolean applies(GameEvent event, Ability source, Game game) { + if (event.getType() == EventType.DRAW_CARD && event.getPlayerId().equals(source.getControllerId())) { + Player player = game.getPlayer(event.getPlayerId()); + if (player.getHand().isEmpty()) { + return true; + } + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/dragonsmaze/UncoveredClues.java b/Mage.Sets/src/mage/sets/dragonsmaze/UncoveredClues.java new file mode 100644 index 0000000000..040a2b4575 --- /dev/null +++ b/Mage.Sets/src/mage/sets/dragonsmaze/UncoveredClues.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ + +package mage.sets.dragonsmaze; + +import java.util.UUID; +import mage.Constants.CardType; +import mage.Constants.Rarity; +import mage.abilities.effects.common.LookLibraryAndPickControllerEffect; +import mage.cards.CardImpl; +import mage.filter.FilterCard; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; + +/** + * + * @author LevelX2 + */ + + +public class UncoveredClues extends CardImpl { + + private static final FilterCard filter = new FilterCard("up to two instant and/or sorcery cards"); + static { + filter.add(Predicates.or(new CardTypePredicate(CardType.INSTANT), new CardTypePredicate(CardType.SORCERY))); + } + + public UncoveredClues(UUID ownerId) { + super(ownerId, 19, "Uncovered Clues", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{2}{U}"); + this.expansionSetCode = "DGM"; + + this.color.setBlue(true); + + // Look at the top four cards of your library. You may reveal up to two instant and/or sorcery cards from among them and put the revealed cards into your hand. Put the rest on the bottom of your library in any order. + this.getSpellAbility().addEffect(new LookLibraryAndPickControllerEffect(4, 2, filter, true)); + } + + public UncoveredClues(final UncoveredClues card) { + super(card); + } + + @Override + public UncoveredClues copy() { + return new UncoveredClues(this); + } +} diff --git a/Mage.Sets/src/mage/sets/dragonsmaze/WakeTheReflections.java b/Mage.Sets/src/mage/sets/dragonsmaze/WakeTheReflections.java new file mode 100644 index 0000000000..b938366a93 --- /dev/null +++ b/Mage.Sets/src/mage/sets/dragonsmaze/WakeTheReflections.java @@ -0,0 +1,63 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ + +package mage.sets.dragonsmaze; + +import java.util.UUID; +import mage.Constants.CardType; +import mage.Constants.Rarity; +import mage.abilities.effects.common.PopulateEffect; +import mage.cards.CardImpl; + +/** + * + * @author LevelX2 + */ + + +public class WakeTheReflections extends CardImpl { + + public WakeTheReflections(UUID ownerId) { + super(ownerId, 10, "Wake the Reflections", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{W}"); + this.expansionSetCode = "DGM"; + + this.color.setWhite(true); + + // Populate. + this.getSpellAbility().addEffect(new PopulateEffect()); + } + + public WakeTheReflections(final WakeTheReflections card) { + super(card); + } + + @Override + public WakeTheReflections copy() { + return new WakeTheReflections(this); + } +}