1
0
Fork 0
mirror of https://github.com/correl/mage.git synced 2025-04-09 17:00:09 -09:00

remove redundant casts

This commit is contained in:
igoudt 2017-09-29 23:53:45 +02:00
parent ff65800ceb
commit 61f14ea97a
2 changed files with 8 additions and 6 deletions
Mage.Sets/src/mage/cards/a

View file

@ -27,7 +27,6 @@
*/ */
package mage.cards.a; package mage.cards.a;
import java.util.UUID;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.Mode; import mage.abilities.Mode;
import mage.abilities.effects.common.ReturnToHandTargetEffect; import mage.abilities.effects.common.ReturnToHandTargetEffect;
@ -35,13 +34,16 @@ import mage.cards.CardImpl;
import mage.cards.CardSetInfo; import mage.cards.CardSetInfo;
import mage.constants.CardType; import mage.constants.CardType;
import mage.filter.FilterCard; import mage.filter.FilterCard;
import static mage.filter.StaticFilters.FILTER_PERMANENT_CREATURES;
import mage.filter.predicate.mageobject.NamePredicate; import mage.filter.predicate.mageobject.NamePredicate;
import mage.game.Game; import mage.game.Game;
import mage.players.Player; import mage.players.Player;
import mage.target.Target; import mage.target.Target;
import mage.target.TargetPermanent; import mage.target.TargetPermanent;
import java.util.UUID;
import static mage.filter.StaticFilters.FILTER_PERMANENT_CREATURES;
/** /**
* *
* @author magenoxx_at_gmail.com * @author magenoxx_at_gmail.com
@ -76,7 +78,7 @@ public class AetherBurst extends CardImpl {
} }
} }
} }
((DynamicTargetCreaturePermanent) target).setMaxNumberOfTargets(amount + 1); target.setMaxNumberOfTargets(amount + 1);
} }
} }

View file

@ -27,8 +27,6 @@
*/ */
package mage.cards.a; package mage.cards.a;
import java.util.List;
import java.util.UUID;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.OneShotEffect;
import mage.cards.*; import mage.cards.*;
@ -40,6 +38,8 @@ import mage.game.Game;
import mage.players.Player; import mage.players.Player;
import mage.target.TargetCard; import mage.target.TargetCard;
import java.util.UUID;
/** /**
* *
* @author Quercitron * @author Quercitron
@ -99,7 +99,7 @@ class AncestralMemoriesEffect extends OneShotEffect {
TargetCard target = new TargetCard(Math.min(2, cards.size()), Zone.LIBRARY, new FilterCard("two cards to put in your hand")); TargetCard target = new TargetCard(Math.min(2, cards.size()), Zone.LIBRARY, new FilterCard("two cards to put in your hand"));
if (player.choose(Outcome.Benefit, cards, target, game)) { if (player.choose(Outcome.Benefit, cards, target, game)) {
for (UUID targetId : (List<UUID>)target.getTargets()) { for (UUID targetId : target.getTargets()) {
Card card = cards.get(targetId, game); Card card = cards.get(targetId, game);
if (card != null) { if (card != null) {
card.moveToZone(Zone.HAND, source.getSourceId(), game, false); card.moveToZone(Zone.HAND, source.getSourceId(), game, false);