mirror of
https://github.com/magefree/mage.git
synced 2025-12-26 05:22:02 -08:00
[NEO] Implemented Azusa's Many Journeys / Likeness of the Seeker
This commit is contained in:
parent
94b1472ad6
commit
8477260070
4 changed files with 109 additions and 3 deletions
|
|
@ -4,6 +4,7 @@ import java.util.UUID;
|
|||
import mage.abilities.Ability;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.TargetController;
|
||||
import mage.filter.common.FilterLandPermanent;
|
||||
import mage.filter.predicate.permanent.TappedPredicate;
|
||||
import mage.game.Game;
|
||||
|
|
@ -17,11 +18,15 @@ import mage.util.CardUtil;
|
|||
*/
|
||||
public class UntapLandsEffect extends OneShotEffect {
|
||||
|
||||
private static final FilterLandPermanent filter = new FilterLandPermanent("land(s) to untap");
|
||||
private static final FilterLandPermanent filterAll = new FilterLandPermanent("land(s) to untap");
|
||||
private static final FilterLandPermanent filterControlled = new FilterLandPermanent("land(s) to untap");
|
||||
|
||||
static {
|
||||
filter.add(TappedPredicate.TAPPED);
|
||||
filterAll.add(TappedPredicate.TAPPED);
|
||||
filterControlled.add(TappedPredicate.TAPPED);
|
||||
filterControlled.add(TargetController.YOU.getControllerPredicate());
|
||||
}
|
||||
private final FilterLandPermanent filter;
|
||||
private final int amount;
|
||||
private final boolean upTo;
|
||||
|
||||
|
|
@ -30,16 +35,22 @@ public class UntapLandsEffect extends OneShotEffect {
|
|||
}
|
||||
|
||||
public UntapLandsEffect(int amount, boolean upTo) {
|
||||
this(amount, upTo, false);
|
||||
}
|
||||
|
||||
public UntapLandsEffect(int amount, boolean upTo, boolean onlyControlled) {
|
||||
super(Outcome.Untap);
|
||||
this.amount = amount;
|
||||
this.upTo = upTo;
|
||||
staticText = "untap " + (upTo ? "up to " : "") + CardUtil.numberToText(amount, staticText) + " lands";
|
||||
this.filter = onlyControlled ? filterControlled : filterAll;
|
||||
staticText = "untap " + (upTo ? "up to " : "") + CardUtil.numberToText(amount, staticText) + " lands" + (onlyControlled ? " you control" : "");
|
||||
}
|
||||
|
||||
public UntapLandsEffect(final UntapLandsEffect effect) {
|
||||
super(effect);
|
||||
this.amount = effect.amount;
|
||||
this.upTo = effect.upTo;
|
||||
this.filter = effect.filter;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue