mirror of
https://github.com/Relintai/mtg-forge-ios.git
synced 2025-01-08 15:39:35 +01:00
- Fixed a NPE in DiscardEffect.
git-svn-id: http://svn.slightlymagic.net/forge/trunk@35801 269b9781-a132-4a9b-9d4e-f004f1b56b58
This commit is contained in:
parent
86b62623e3
commit
9bcfced7d2
@ -293,11 +293,11 @@ public class DiscardEffect extends SpellAbilityEffect {
|
||||
|
||||
CardCollectionView toBeDiscarded = validCards.isEmpty() ? null : chooser.getController().chooseCardsToDiscardFrom(p, sa, validCards, min, max);
|
||||
|
||||
if (toBeDiscarded.size() > 1) {
|
||||
toBeDiscarded = GameActionUtil.orderCardsByTheirOwners(p.getGame(), toBeDiscarded, ZoneType.Graveyard);
|
||||
}
|
||||
|
||||
if (toBeDiscarded != null) {
|
||||
if (toBeDiscarded.size() > 1) {
|
||||
toBeDiscarded = GameActionUtil.orderCardsByTheirOwners(p.getGame(), toBeDiscarded, ZoneType.Graveyard);
|
||||
}
|
||||
|
||||
if (mode.startsWith("Reveal") ) {
|
||||
p.getController().reveal(toBeDiscarded, ZoneType.Hand, p,
|
||||
chooser + " has chosen " + (toBeDiscarded.size() == 1 ? "this card" : "these cards") + " from ");
|
||||
|
Loading…
Reference in New Issue
Block a user