mirror of
https://github.com/correl/mage.git
synced 2024-12-26 03:00:11 +00:00
fixed Kiora, Master of the Depths (NPE errors)
This commit is contained in:
parent
56d52899c8
commit
aa678a3b00
1 changed files with 8 additions and 4 deletions
|
@ -143,14 +143,18 @@ class KioraRevealEffect extends OneShotEffect {
|
|||
if (creatureCardFound) {
|
||||
TargetCard target = new TargetCardInLibrary(0, 1, creatureFilter);
|
||||
controller.chooseTarget(Outcome.DrawCard, cards, target, source, game);
|
||||
cards.remove(target.getFirstTarget());
|
||||
cardsToHand.add(target.getFirstTarget());
|
||||
if (target.getFirstTarget() != null) {
|
||||
cards.remove(target.getFirstTarget());
|
||||
cardsToHand.add(target.getFirstTarget());
|
||||
}
|
||||
}
|
||||
if (landCardFound) {
|
||||
TargetCard target = new TargetCardInLibrary(0, 1, landFilter);
|
||||
controller.chooseTarget(Outcome.DrawCard, cards, target, source, game);
|
||||
cards.remove(target.getFirstTarget());
|
||||
cardsToHand.add(target.getFirstTarget());
|
||||
if (target.getFirstTarget() != null) {
|
||||
cards.remove(target.getFirstTarget());
|
||||
cardsToHand.add(target.getFirstTarget());
|
||||
}
|
||||
}
|
||||
controller.moveCards(cardsToHand, Zone.HAND, source, game);
|
||||
controller.moveCards(cards, Zone.GRAVEYARD, source, game);
|
||||
|
|
Loading…
Reference in a new issue