mirror of
https://github.com/magefree/mage.git
synced 2025-12-26 05:22:02 -08:00
fixed issue with ExileCardYouChooseTargetOpponentEffect not revealing hand when no matching cards (fixes #8840)
This commit is contained in:
parent
a491413abf
commit
f26c1d7bc0
1 changed files with 4 additions and 2 deletions
|
|
@ -33,11 +33,13 @@ public class ExileCardYouChooseTargetOpponentEffect extends OneShotEffect {
|
|||
public boolean apply(Game game, Ability source) {
|
||||
Player controller = game.getPlayer(source.getControllerId());
|
||||
Player opponent = game.getPlayer(source.getFirstTarget());
|
||||
if (controller == null || opponent == null
|
||||
|| opponent.getHand().count(filter, game) < 1) {
|
||||
if (controller == null || opponent == null) {
|
||||
return false;
|
||||
}
|
||||
opponent.revealCards(source, opponent.getHand(), game);
|
||||
if (opponent.getHand().count(filter, game) < 1) {
|
||||
return true;
|
||||
}
|
||||
TargetCard target = new TargetCard(Zone.HAND, filter);
|
||||
controller.choose(Outcome.Exile, opponent.getHand(), target, game);
|
||||
Card card = opponent.getHand().get(target.getFirstTarget(), game);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue