From 3c918be7171b10c87d86606b2e231d562be5fc4a Mon Sep 17 00:00:00 2001 From: Agetian Date: Wed, 6 Mar 2013 07:17:33 +0000 Subject: [PATCH] - The real (hopefully) fix for the split card LQ pictures not being downloaded correctly from a picture URL. --- src/main/java/forge/gui/download/GuiDownloadPicturesLQ.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/main/java/forge/gui/download/GuiDownloadPicturesLQ.java b/src/main/java/forge/gui/download/GuiDownloadPicturesLQ.java index f4ad0762fc2..46b8b344e86 100644 --- a/src/main/java/forge/gui/download/GuiDownloadPicturesLQ.java +++ b/src/main/java/forge/gui/download/GuiDownloadPicturesLQ.java @@ -67,7 +67,11 @@ public class GuiDownloadPicturesLQ extends GuiDownloader { for (final IPaperCard c : CardDb.instance().getUniqueCards()) { //System.out.println(c.getName()); CardRules cardRules = c.getRules(); - this.createDLObjects(cardRules.getPictureUrl(), cardRules.getMainPart().getName()); + if (cardRules != null && cardRules.getSplitType() == CardSplitType.Split && cardRules.getOtherPart() != null) { + this.createDLObjects(cardRules.getPictureUrl(), String.format("%s%s", cardRules.getMainPart().getName(), cardRules.getOtherPart().getName())); + } else { + this.createDLObjects(cardRules.getPictureUrl(), cardRules.getMainPart().getName()); + } ICardCharacteristics secondSide = cardRules.getOtherPart(); if (secondSide != null && cardRules.getSplitType() == CardSplitType.Transform) {