mirror of
https://github.com/magefree/mage.git
synced 2025-12-25 04:52:07 -08:00
[EMN] Added some blue cards.
This commit is contained in:
parent
e01a594ef8
commit
753e7dfb2c
9 changed files with 515 additions and 87 deletions
|
|
@ -193,42 +193,40 @@ public class LookLibraryAndPickControllerEffect extends LookLibraryControllerEff
|
|||
if (revealPickedCards) {
|
||||
sb.append(". You may reveal ");
|
||||
sb.append(filter.getMessage()).append(" from among them and put it into your ");
|
||||
} else if (targetPickedCards.equals(Zone.BATTLEFIELD)) {
|
||||
sb.append(". You ");
|
||||
if (optional) {
|
||||
sb.append("may ");
|
||||
}
|
||||
sb.append("put ").append(filter.getMessage()).append(" from among them onto the ");
|
||||
} else {
|
||||
if (targetPickedCards.equals(Zone.BATTLEFIELD)) {
|
||||
sb.append(". You ");
|
||||
if (optional) {
|
||||
sb.append("may ");
|
||||
}
|
||||
sb.append("put ").append(filter.getMessage()).append(" from among them onto the ");
|
||||
} else {
|
||||
sb.append(". Put ");
|
||||
if (numberToPick.calculate(null, null, this) > 1) {
|
||||
if (upTo) {
|
||||
if (numberToPick.calculate(null, null, this) == (numberOfCards.calculate(null, null, this))) {
|
||||
sb.append("any number");
|
||||
} else {
|
||||
sb.append("up to ").append(CardUtil.numberToText(numberToPick.calculate(null, null, this)));
|
||||
}
|
||||
sb.append(". Put ");
|
||||
if (numberToPick.calculate(null, null, this) > 1) {
|
||||
if (upTo) {
|
||||
if (numberToPick.calculate(null, null, this) == (numberOfCards.calculate(null, null, this))) {
|
||||
sb.append("any number");
|
||||
} else {
|
||||
sb.append(CardUtil.numberToText(numberToPick.calculate(null, null, this)));
|
||||
sb.append("up to ").append(CardUtil.numberToText(numberToPick.calculate(null, null, this)));
|
||||
}
|
||||
} else {
|
||||
sb.append("one");
|
||||
sb.append(CardUtil.numberToText(numberToPick.calculate(null, null, this)));
|
||||
}
|
||||
|
||||
sb.append(" of them into your ");
|
||||
} else {
|
||||
sb.append("one");
|
||||
}
|
||||
|
||||
sb.append(" of them into your ");
|
||||
}
|
||||
sb.append(targetPickedCards.toString().toLowerCase());
|
||||
|
||||
if (targetZoneLookedCards == Zone.LIBRARY) {
|
||||
sb.append(". Put the rest ");
|
||||
if (putOnTop) {
|
||||
sb.append("back ");
|
||||
sb.append("back on top");
|
||||
} else {
|
||||
sb.append("on the bottom of your library ");
|
||||
sb.append("on the bottom");
|
||||
}
|
||||
sb.append("in any order");
|
||||
sb.append(" of your library in any order");
|
||||
} else if (targetZoneLookedCards == Zone.GRAVEYARD) {
|
||||
sb.append(" and the other into your graveyard");
|
||||
}
|
||||
|
|
|
|||
|
|
@ -31,6 +31,8 @@ import java.util.UUID;
|
|||
import mage.abilities.Ability;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.cards.Card;
|
||||
import mage.cards.Cards;
|
||||
import mage.cards.CardsImpl;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.Zone;
|
||||
import mage.game.ExileZone;
|
||||
|
|
@ -75,20 +77,24 @@ public class ReturnToBattlefieldUnderYourControlTargetEffect extends OneShotEffe
|
|||
public boolean apply(Game game, Ability source) {
|
||||
Player controller = game.getPlayer(source.getControllerId());
|
||||
if (controller != null) {
|
||||
Card card = null;
|
||||
Cards cardsToBattlefield = new CardsImpl();
|
||||
if (fromExileZone) {
|
||||
UUID exilZoneId = CardUtil.getExileZoneId(game, source.getSourceId(), source.getSourceObjectZoneChangeCounter());
|
||||
if (exilZoneId != null) {
|
||||
ExileZone exileZone = game.getExile().getExileZone(exilZoneId);
|
||||
if (exileZone != null && getTargetPointer().getFirst(game, source) != null) {
|
||||
card = exileZone.get(getTargetPointer().getFirst(game, source), game);
|
||||
if (exileZone != null) {
|
||||
for (Card card : exileZone.getCards(game)) {
|
||||
if (getTargetPointer().getTargets(game, source).contains(card.getId())) {
|
||||
cardsToBattlefield.add(card);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
card = game.getCard(getTargetPointer().getFirst(game, source));
|
||||
cardsToBattlefield.addAll(getTargetPointer().getTargets(game, source));
|
||||
}
|
||||
if (card != null) {
|
||||
controller.moveCards(card, Zone.BATTLEFIELD, source, game);
|
||||
if (!cardsToBattlefield.isEmpty()) {
|
||||
controller.moveCards(cardsToBattlefield, Zone.BATTLEFIELD, source, game);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue