mirror of
https://github.com/correl/mage.git
synced 2025-01-12 19:25:44 +00:00
fixed issue 13
This commit is contained in:
parent
83074c9b1a
commit
10cdf10da6
1 changed files with 7 additions and 2 deletions
|
@ -55,8 +55,13 @@ public class DiscardSourceCost extends CostImpl<DiscardSourceCost> {
|
|||
@Override
|
||||
public boolean pay(Game game, UUID sourceId, UUID controllerId, boolean noMana) {
|
||||
Player player = game.getPlayer(controllerId);
|
||||
Card card = player.getHand().get(sourceId, game);
|
||||
return player.discard(card, null, game);
|
||||
if (player != null) {
|
||||
Card card = player.getHand().get(sourceId, game);
|
||||
if (card != null) {
|
||||
paid = player.discard(card, null, game);
|
||||
}
|
||||
}
|
||||
return paid;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
Loading…
Reference in a new issue