mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-20 04:38:00 +00:00
Fix issue where quest icons wouldn't appear
This commit is contained in:
@@ -38,6 +38,7 @@ public interface IGuiBase {
|
||||
boolean isGuiThread();
|
||||
String getAssetsDir();
|
||||
boolean mayShowCard(Card card);
|
||||
ISkinImage getSkinIcon(FSkinProp skinProp);
|
||||
ISkinImage getUnskinnedIcon(String path);
|
||||
void showBugReportDialog(String title, String text, boolean showExitAppBtn);
|
||||
int showOptionDialog(String message, String title, FSkinProp icon, String[] options, int defaultOption);
|
||||
|
||||
@@ -19,6 +19,8 @@ package forge.quest.bazaar;
|
||||
|
||||
import com.thoughtworks.xstream.annotations.XStreamAsAttribute;
|
||||
|
||||
import forge.GuiBase;
|
||||
import forge.assets.FSkinProp;
|
||||
import forge.assets.ISkinImage;
|
||||
import forge.quest.data.QuestAssets;
|
||||
|
||||
@@ -66,6 +68,9 @@ public class QuestItemBasic implements IQuestBazaarItem {
|
||||
return this.basePrice;
|
||||
}
|
||||
|
||||
@XStreamAsAttribute
|
||||
private final FSkinProp icon = null;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* Constructor for QuestItemAbstract.
|
||||
@@ -163,7 +168,7 @@ public class QuestItemBasic implements IQuestBazaarItem {
|
||||
*/
|
||||
@Override
|
||||
public ISkinImage getIcon(QuestAssets qA) {
|
||||
return null;
|
||||
return GuiBase.getInterface().getSkinIcon(icon);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -20,6 +20,8 @@ package forge.quest.bazaar;
|
||||
import com.thoughtworks.xstream.annotations.XStreamAlias;
|
||||
import com.thoughtworks.xstream.annotations.XStreamAsAttribute;
|
||||
|
||||
import forge.GuiBase;
|
||||
import forge.assets.FSkinProp;
|
||||
import forge.assets.ISkinImage;
|
||||
|
||||
import java.util.ArrayList;
|
||||
@@ -45,7 +47,7 @@ public class QuestStallDefinition {
|
||||
private final String displayName;
|
||||
|
||||
@XStreamAsAttribute
|
||||
private final ISkinImage icon;
|
||||
private final FSkinProp icon;
|
||||
|
||||
private final String description;
|
||||
|
||||
@@ -88,7 +90,7 @@ public class QuestStallDefinition {
|
||||
* @return the icon
|
||||
*/
|
||||
public ISkinImage getIcon() {
|
||||
return icon;
|
||||
return GuiBase.getInterface().getSkinIcon(icon);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user