mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-18 19:58:00 +00:00
fix crash when showing uninitialized zone
This commit is contained in:
@@ -123,11 +123,16 @@ public class FloatingZone extends FloatingCardArea {
|
|||||||
};
|
};
|
||||||
|
|
||||||
protected Iterable<CardView> getCards() {
|
protected Iterable<CardView> getCards() {
|
||||||
cardList = new FCollection<CardView>(player.getCards(zone));
|
Iterable<CardView> zoneCards = player.getCards(zone);
|
||||||
if ( sortedByName ) {
|
if ( zoneCards != null ) {
|
||||||
Collections.sort(cardList, comp);
|
cardList = new FCollection<CardView>(player.getCards(zone));
|
||||||
}
|
if ( sortedByName ) {
|
||||||
return cardList;
|
Collections.sort(cardList, comp);
|
||||||
|
}
|
||||||
|
return cardList;
|
||||||
|
} else {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private FloatingZone(final CMatchUI matchUI, final PlayerView player0, final ZoneType zone0) {
|
private FloatingZone(final CMatchUI matchUI, final PlayerView player0, final ZoneType zone0) {
|
||||||
|
|||||||
Reference in New Issue
Block a user