mirror of
https://github.com/correl/mage.git
synced 2024-12-26 11:09:27 +00:00
* Winds of Change - Fixed a Concurrent Modification Exception bug.
This commit is contained in:
parent
9ece8a21f6
commit
859e945799
1 changed files with 3 additions and 6 deletions
|
@ -90,13 +90,10 @@ class WindsOfChangeEffect extends OneShotEffect {
|
||||||
if (player != null) {
|
if (player != null) {
|
||||||
int cardsHand = player.getHand().size();
|
int cardsHand = player.getHand().size();
|
||||||
if (cardsHand > 0){
|
if (cardsHand > 0){
|
||||||
for (UUID cardId: player.getHand()) {
|
for (Card card: player.getHand().getCards(game)) {
|
||||||
Card card = game.getCard(cardId);
|
|
||||||
if (card != null) {
|
|
||||||
player.removeFromHand(card, game);
|
player.removeFromHand(card, game);
|
||||||
card.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true);
|
card.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
game.informPlayers(player.getName() + " shuffles the cards from his or her hand into his or her library");
|
game.informPlayers(player.getName() + " shuffles the cards from his or her hand into his or her library");
|
||||||
player.shuffleLibrary(game);
|
player.shuffleLibrary(game);
|
||||||
player.drawCards(cardsHand, game);
|
player.drawCards(cardsHand, game);
|
||||||
|
|
Loading…
Reference in a new issue