mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-16 18:58:00 +00:00
Adventure fixes: "No Sell Cards", quest tracking
This commit is contained in:
@@ -295,6 +295,7 @@ public class AdventureQuestStage implements Serializable {
|
|||||||
} else {
|
} else {
|
||||||
status = ++progress4 >= count4 && count4 > 0 ? FAILED : status;
|
status = ++progress4 >= count4 && count4 > 0 ? FAILED : status;
|
||||||
}
|
}
|
||||||
|
break;
|
||||||
case Arena:
|
case Arena:
|
||||||
status = event.type == AdventureQuestEventType.ARENACOMPLETE
|
status = event.type == AdventureQuestEventType.ARENACOMPLETE
|
||||||
&& event.winner //if event won & not conceded
|
&& event.winner //if event won & not conceded
|
||||||
|
|||||||
@@ -453,29 +453,24 @@ public class AdventurePlayer implements Serializable, SaveFileContent {
|
|||||||
setSelectedDeckSlot(data.readInt("selectedDeckIndex"));
|
setSelectedDeckSlot(data.readInt("selectedDeckIndex"));
|
||||||
cards.addAll(CardPool.fromCardList(Lists.newArrayList((String[]) data.readObject("cards"))));
|
cards.addAll(CardPool.fromCardList(Lists.newArrayList((String[]) data.readObject("cards"))));
|
||||||
|
|
||||||
//newCards.addAll(InventoryItem data.readObject("cards"))));
|
if (data.containsKey("newCards")) {
|
||||||
data.storeObject("newCards", newCards.toFlatList().toArray(new InventoryItem[0]));
|
InventoryItem[] items = (InventoryItem[]) data.readObject("newCards");
|
||||||
data.storeObject("autoSellCards", autoSellCards.toFlatList().toArray(new InventoryItem[0]));
|
for (InventoryItem item : items){
|
||||||
data.storeObject("noSellCards", noSellCards.toFlatList().toArray(new InventoryItem[0]));
|
newCards.add((PaperCard)item);
|
||||||
|
}
|
||||||
// if (data.containsKey("newCards")) {
|
}
|
||||||
// InventoryItem[] items = (InventoryItem[]) data.readObject("newCards");
|
if (data.containsKey("noSellCards")) {
|
||||||
// for (InventoryItem item : items){
|
PaperCard[] items = (PaperCard[]) data.readObject("noSellCards");
|
||||||
// newCards.add((PaperCard)item);
|
for (PaperCard item : items){
|
||||||
// }
|
noSellCards.add(item);
|
||||||
// }
|
}
|
||||||
// if (data.containsKey("noSellCards")) {
|
}
|
||||||
// PaperCard[] items = (PaperCard[]) data.readObject("noSellCards");
|
if (data.containsKey("autoSellCards")) {
|
||||||
// for (PaperCard item : items){
|
PaperCard[] items = (PaperCard[]) data.readObject("autoSellCards");
|
||||||
// noSellCards.add(item);
|
for (PaperCard item : items){
|
||||||
// }
|
autoSellCards.add(item);
|
||||||
// }
|
}
|
||||||
// if (data.containsKey("autoSellCards")) {
|
}
|
||||||
// PaperCard[] items = (PaperCard[]) data.readObject("autoSellCards");
|
|
||||||
// for (PaperCard item : items){
|
|
||||||
// autoSellCards.add(item);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
|
|
||||||
fantasyMode = data.containsKey("fantasyMode") && data.readBool("fantasyMode");
|
fantasyMode = data.containsKey("fantasyMode") && data.readBool("fantasyMode");
|
||||||
announceFantasy = data.containsKey("announceFantasy") && data.readBool("announceFantasy");
|
announceFantasy = data.containsKey("announceFantasy") && data.readBool("announceFantasy");
|
||||||
|
|||||||
Reference in New Issue
Block a user