mirror of
https://github.com/magefree/mage.git
synced 2026-01-25 12:49:39 -08:00
* Jace's Archivist - fixed AI freeze the game (#5023);
This commit is contained in:
parent
97712971fa
commit
ef4c223bcf
2 changed files with 18 additions and 14 deletions
|
|
@ -10,6 +10,7 @@ import mage.abilities.costs.mana.ColoredManaCost;
|
|||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.cards.Cards;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SubType;
|
||||
import mage.constants.ColoredManaSymbol;
|
||||
|
|
@ -66,13 +67,13 @@ class JacesArchivistEffect extends OneShotEffect {
|
|||
for (UUID playerId : game.getState().getPlayersInRange(controller.getId(), game)) {
|
||||
Player player = game.getPlayer(playerId);
|
||||
if (player != null) {
|
||||
int discarded = player.getHand().size();
|
||||
player.discard(discarded, false, source, game);
|
||||
if (discarded > maxDiscarded) {
|
||||
maxDiscarded = discarded;
|
||||
Cards discardedCards = player.discard(player.getHand().size(), false, source, game);
|
||||
if (discardedCards.size() > maxDiscarded) {
|
||||
maxDiscarded = discardedCards.size();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
for (UUID playerId : game.getState().getPlayersInRange(controller.getId(), game)) {
|
||||
Player player = game.getPlayer(playerId);
|
||||
if (player != null) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue