mirror of
https://github.com/magefree/mage.git
synced 2025-12-28 06:22:01 -08:00
- Fixed Soul Strings. DoUnlessAnyPlayerPays now supports X costs.
This commit is contained in:
parent
9916dbdad7
commit
1bac7fc04c
5 changed files with 62 additions and 16 deletions
|
|
@ -861,6 +861,19 @@ public class ComputerPlayer extends PlayerImpl implements Player {
|
|||
}
|
||||
return target.isChosen();
|
||||
}
|
||||
|
||||
if (target.getOriginalTarget() instanceof TargetCardInGraveyardOrBattlefield) {
|
||||
List<Card> cards = new ArrayList<>();
|
||||
for (Player player : game.getPlayers().values()) {
|
||||
cards.addAll(player.getGraveyard().getCards(game));
|
||||
cards.addAll(game.getBattlefield().getAllActivePermanents(new FilterPermanent(), player.getId(), game));
|
||||
}
|
||||
Card card = pickTarget(cards, outcome, target, source, game);
|
||||
if (card != null) {
|
||||
target.addTarget(card.getId(), source, game);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
throw new IllegalStateException("Target wasn't handled. class:" + target.getClass().toString());
|
||||
} //end of chooseTarget method
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue