forked from External/mage
[GRN] Some more fixes.
This commit is contained in:
parent
b815c4c053
commit
3eb4df5fbe
2 changed files with 14 additions and 8 deletions
|
|
@ -65,8 +65,8 @@ class DeviousCoverUpEffect extends OneShotEffect {
|
|||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
Player player = game.getPlayer(source.getFirstTarget());
|
||||
if (player == null || !player.chooseUse(outcome, "Shuffle the targeted cards into your library?", source, game)) {
|
||||
Player controller = game.getPlayer(source.getControllerId());
|
||||
if (controller == null || !controller.chooseUse(outcome, "Shuffle the targeted cards into your library?", source, game)) {
|
||||
return false;
|
||||
}
|
||||
Cards cards = new CardsImpl();
|
||||
|
|
@ -76,8 +76,8 @@ class DeviousCoverUpEffect extends OneShotEffect {
|
|||
cards.add(card);
|
||||
}
|
||||
}
|
||||
player.getLibrary().addAll(cards.getCards(game), game);
|
||||
player.shuffleLibrary(source, game);
|
||||
controller.putCardsOnTopOfLibrary(cards, game, source, false);
|
||||
controller.shuffleLibrary(source, game);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,12 +8,12 @@ import mage.abilities.effects.OneShotEffect;
|
|||
import mage.abilities.effects.common.ShuffleIntoLibrarySourceEffect;
|
||||
import mage.abilities.keyword.CantBeBlockedSourceAbility;
|
||||
import mage.cards.Card;
|
||||
import mage.constants.SubType;
|
||||
import mage.constants.SuperType;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SubType;
|
||||
import mage.constants.SuperType;
|
||||
import mage.constants.Zone;
|
||||
import mage.counters.CounterType;
|
||||
import mage.filter.FilterCard;
|
||||
|
|
@ -102,7 +102,7 @@ class EtrataTheSilencerTriggeredAbility extends TriggeredAbilityImpl {
|
|||
+ "and put a hit counter on that card. "
|
||||
+ "That player loses the game if they own three or more "
|
||||
+ "exiled cards with hit counters on them. "
|
||||
+ "{this}'s owner shuffles {this} into their library.";
|
||||
+ "{this}'s owner shuffles {this} into their library";
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -143,7 +143,13 @@ class EtrataTheSilencerEffect extends OneShotEffect {
|
|||
if (card != null) {
|
||||
card.addCounters(CounterType.HIT.createInstance(), source, game);
|
||||
}
|
||||
if (game.getExile().getExileZone(player.getId()).count(filter, game) > 2) {
|
||||
int cardsFound = 0;
|
||||
for (Card exiledCard : game.getExile().getAllCards(game)) {
|
||||
if (exiledCard.getCounters(game).getCount(CounterType.HIT) > 1 && exiledCard.getOwnerId().equals(player.getId())) {
|
||||
cardsFound++;
|
||||
}
|
||||
}
|
||||
if (cardsFound > 2) {
|
||||
player.lost(game);
|
||||
}
|
||||
return new ShuffleIntoLibrarySourceEffect().apply(game, source);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue