diff --git a/Mage.Sets/src/mage/cards/d/DisposalMummy.java b/Mage.Sets/src/mage/cards/d/DisposalMummy.java
index b3e82deac7..bd05d1fbfa 100644
--- a/Mage.Sets/src/mage/cards/d/DisposalMummy.java
+++ b/Mage.Sets/src/mage/cards/d/DisposalMummy.java
@@ -31,6 +31,7 @@ import java.util.UUID;
import mage.MageInt;
import mage.abilities.Ability;
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
+import mage.abilities.effects.common.ExileTargetEffect;
import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
@@ -43,10 +44,10 @@ import mage.target.common.TargetCardInOpponentsGraveyard;
* @author Archer262
*/
public class DisposalMummy extends CardImpl {
-
+
public DisposalMummy(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{W}");
-
+
this.subtype.add("Zombie");
this.subtype.add("Jackal");
this.power = new MageInt(2);
@@ -58,11 +59,11 @@ public class DisposalMummy extends CardImpl {
ability.addTarget(target);
this.addAbility(ability);
}
-
+
public DisposalMummy(final DisposalMummy card) {
super(card);
}
-
+
@Override
public DisposalMummy copy() {
return new DisposalMummy(this);
diff --git a/Mage.Sets/src/mage/cards/d/Doomfall.java b/Mage.Sets/src/mage/cards/d/Doomfall.java
index 66caa1c9b0..78c30c55e6 100644
--- a/Mage.Sets/src/mage/cards/d/Doomfall.java
+++ b/Mage.Sets/src/mage/cards/d/Doomfall.java
@@ -41,7 +41,6 @@ import mage.filter.StaticFilters;
import mage.game.Game;
import mage.players.Player;
import mage.target.Target;
-import mage.target.TargetPlayer;
import mage.target.common.TargetControlledCreaturePermanent;
import mage.target.common.TargetOpponent;
@@ -58,9 +57,9 @@ public class Doomfall extends CardImpl {
this.getSpellAbility().getModes().setMinModes(1);
this.getSpellAbility().getModes().setMaxModes(1);
- // • Target player exiles a creature he or she controls.
+ // • Target opponent exiles a creature he or she controls.
this.getSpellAbility().addEffect(new DoomfallEffect());
- this.getSpellAbility().addTarget(new TargetPlayer());
+ this.getSpellAbility().addTarget(new TargetOpponent());
// • Target opponent reveals his or her hand. You choose a nonland card from it. Exile that card.
Mode mode = new Mode();
@@ -103,7 +102,7 @@ class DoomfallEffect extends OneShotEffect {
Target target = new TargetControlledCreaturePermanent();
target.setNotTarget(true);
if (targetPlayer.choose(outcome, target, source.getSourceId(), game)) {
- targetPlayer.moveCards(game.getCard(target.getFirstTarget()), Zone.EXILED, source, game);
+ targetPlayer.moveCards(game.getPermanent(target.getFirstTarget()), Zone.EXILED, source, game);
}
return true;
}
diff --git a/Mage.Sets/src/mage/cards/d/Duplicant.java b/Mage.Sets/src/mage/cards/d/Duplicant.java
index 8c4cb2256f..60e1118972 100644
--- a/Mage.Sets/src/mage/cards/d/Duplicant.java
+++ b/Mage.Sets/src/mage/cards/d/Duplicant.java
@@ -27,6 +27,7 @@
*/
package mage.cards.d;
+import java.util.UUID;
import mage.MageInt;
import mage.abilities.Ability;
import mage.abilities.Mode;
@@ -45,8 +46,6 @@ import mage.game.Game;
import mage.game.permanent.Permanent;
import mage.target.common.TargetCreaturePermanent;
-import java.util.UUID;
-
/**
*
* @author Plopman
@@ -54,18 +53,20 @@ import java.util.UUID;
public class Duplicant extends CardImpl {
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("nontoken creature");
+
static {
filter.add(Predicates.not(new TokenPredicate()));
}
+
public Duplicant(UUID ownerId, CardSetInfo setInfo) {
- super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT,CardType.CREATURE},"{6}");
+ super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{6}");
this.subtype.add("Shapeshifter");
this.power = new MageInt(2);
this.toughness = new MageInt(4);
// Imprint - When Duplicant enters the battlefield, you may exile target nontoken creature.
- Ability ability = new EntersBattlefieldTriggeredAbility(new ExileTargetEffect(), true, "Imprint - ");
+ Ability ability = new EntersBattlefieldTriggeredAbility(new DuplicantExileTargetEffect(), true, "Imprint - ");
ability.addTarget(new TargetCreaturePermanent(filter));
this.addAbility(ability);
// As long as the exiled card is a creature card, Duplicant has that card's power, toughness, and creature types. It's still a Shapeshifter.
@@ -81,20 +82,20 @@ public class Duplicant extends CardImpl {
return new Duplicant(this);
}
}
-class ExileTargetEffect extends OneShotEffect {
+class DuplicantExileTargetEffect extends OneShotEffect {
- public ExileTargetEffect() {
+ public DuplicantExileTargetEffect() {
super(Outcome.Exile);
}
- public ExileTargetEffect(final ExileTargetEffect effect) {
+ public DuplicantExileTargetEffect(final DuplicantExileTargetEffect effect) {
super(effect);
}
@Override
- public ExileTargetEffect copy() {
- return new ExileTargetEffect(this);
+ public DuplicantExileTargetEffect copy() {
+ return new DuplicantExileTargetEffect(this);
}
@Override
@@ -102,13 +103,13 @@ class ExileTargetEffect extends OneShotEffect {
Permanent permanent = game.getPermanent(targetPointer.getFirst(game, source));
Permanent sourcePermananent = game.getPermanent(source.getSourceId());
if (permanent != null) {
- if(sourcePermananent != null){
+ if (sourcePermananent != null) {
sourcePermananent.imprint(permanent.getId(), game);
sourcePermananent.addInfo("imprint", new StringBuilder("[Imprinted card - ").append(permanent.getName()).append(']').toString(), game);
}
return permanent.moveToExile(null, null, source.getSourceId(), game);
- }
-
+ }
+
return false;
}
@@ -118,17 +119,16 @@ class ExileTargetEffect extends OneShotEffect {
}
}
-
class DuplicantContinuousEffect extends ContinuousEffectImpl {
public DuplicantContinuousEffect() {
super(Duration.WhileOnBattlefield, Outcome.BoostCreature);
- staticText = "As long as the exiled card is a creature card, Duplicant has that card's power, toughness, and creature types. It's still a Shapeshifter";
+ staticText = "As long as the exiled card is a creature card, Duplicant has that card's power, toughness, and creature types. It's still a Shapeshifter";
}
public DuplicantContinuousEffect(final DuplicantContinuousEffect effect) {
super(effect);
- }
+ }
@Override
public DuplicantContinuousEffect copy() {
@@ -139,10 +139,9 @@ class DuplicantContinuousEffect extends ContinuousEffectImpl {
public boolean apply(Layer layer, SubLayer sublayer, Ability source, Game game) {
Permanent permanent = game.getPermanent(source.getSourceId());
if (permanent != null) {
- if(!permanent.getImprinted().isEmpty()){
+ if (!permanent.getImprinted().isEmpty()) {
Card card = game.getCard(permanent.getImprinted().get(0));
- if(card != null && card.isCreature())
- {
+ if (card != null && card.isCreature()) {
switch (layer) {
case TypeChangingEffects_4:
if (sublayer == SubLayer.NA) {
@@ -152,29 +151,28 @@ class DuplicantContinuousEffect extends ContinuousEffectImpl {
break;
case PTChangingEffects_7:
if (sublayer == SubLayer.SetPT_7b) {
- permanent.getPower().setValue(card.getPower().getValue());
- permanent.getToughness().setValue(card.getToughness().getValue());
+ permanent.getPower().setValue(card.getPower().getValue());
+ permanent.getToughness().setValue(card.getToughness().getValue());
}
}
return true;
-
}
}
-
+
}
return false;
}
-
+
@Override
public boolean apply(Game game, Ability source) {
return false;
}
-
+
@Override
public boolean hasLayer(Layer layer) {
return layer == Layer.PTChangingEffects_7 || layer == Layer.TypeChangingEffects_4;
}
-}
\ No newline at end of file
+}
diff --git a/Mage.Sets/src/mage/cards/h/HourOfGlory.java b/Mage.Sets/src/mage/cards/h/HourOfGlory.java
index d46951839b..5cb314cf12 100644
--- a/Mage.Sets/src/mage/cards/h/HourOfGlory.java
+++ b/Mage.Sets/src/mage/cards/h/HourOfGlory.java
@@ -43,6 +43,7 @@ import mage.constants.Zone;
import mage.game.Game;
import mage.game.permanent.Permanent;
import mage.players.Player;
+import mage.target.common.TargetCreaturePermanent;
/**
*
@@ -55,6 +56,7 @@ public class HourOfGlory extends CardImpl {
// Exile target creature. If that creature was a God, its controller reveals his or her hand and exiles all cards with the same name as that creature.
this.getSpellAbility().addEffect(new HourOfGloryEffect());
+ this.getSpellAbility().addTarget(new TargetCreaturePermanent());
}
public HourOfGlory(final HourOfGlory card) {
diff --git a/Mage.Sets/src/mage/cards/t/TormentOfVenom.java b/Mage.Sets/src/mage/cards/t/TormentOfVenom.java
index d7d9e95610..c697f038f8 100644
--- a/Mage.Sets/src/mage/cards/t/TormentOfVenom.java
+++ b/Mage.Sets/src/mage/cards/t/TormentOfVenom.java
@@ -36,7 +36,12 @@ import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.constants.Outcome;
import mage.counters.CounterType;
+import mage.filter.FilterPermanent;
import mage.filter.StaticFilters;
+import mage.filter.common.FilterControlledPermanent;
+import mage.filter.predicate.Predicates;
+import mage.filter.predicate.mageobject.CardTypePredicate;
+import mage.filter.predicate.permanent.PermanentIdPredicate;
import mage.game.Game;
import mage.game.permanent.Permanent;
import mage.players.Player;
@@ -94,7 +99,10 @@ class TormentOfVenomEffect extends OneShotEffect {
int permanents = game.getBattlefield().countAll(StaticFilters.FILTER_PERMANENT_NON_LAND, controllingPlayer.getId(), game);
if (permanents > 0 && controllingPlayer.chooseUse(outcome, "Sacrifices a nonland permanent?",
"Otherwise you have to discard a card or lose 3 life.", "Sacrifice", "Discard or life loss", source, game)) {
- Target target = new TargetPermanent(StaticFilters.FILTER_CONTROLLED_PERMANENT_NON_LAND);
+ FilterPermanent filter = new FilterControlledPermanent("another nonland permanent");
+ filter.add(Predicates.not(new CardTypePredicate(CardType.LAND)));
+ filter.add(Predicates.not(new PermanentIdPredicate(targetCreature.getId())));
+ Target target = new TargetPermanent(filter);
if (controllingPlayer.choose(outcome, target, source.getSourceId(), game)) {
Permanent permanent = game.getPermanent(target.getFirstTarget());
if (permanent != null) {