forked from External/mage
* Moldgraf Monstrosity - Fixed possible NPE if graveyard does not contain 2 creatures.
This commit is contained in:
parent
aa18ae8773
commit
aee38cbdc8
1 changed files with 3 additions and 0 deletions
|
|
@ -113,6 +113,9 @@ class MoldgrafMonstrosityEffect extends OneShotEffect<MoldgrafMonstrosityEffect>
|
|||
}
|
||||
|
||||
private Card getRandomCard(Set<Card> cards) {
|
||||
if (cards == null || cards.size() < 1) {
|
||||
return null;
|
||||
}
|
||||
int i = 0;
|
||||
int pick = new Random().nextInt(cards.size());
|
||||
for (Card card : cards) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue