Fix display of map screen

Fix so deck gets saved
This commit is contained in:
drdev
2014-11-23 05:19:04 +00:00
parent 769b5c1b37
commit a17394f36d
3 changed files with 13 additions and 2 deletions

View File

@@ -1,6 +1,7 @@
package forge.screens.planarconquest; package forge.screens.planarconquest;
import forge.FThreads; import forge.FThreads;
import forge.model.FModel;
import forge.quest.QuestUtil; import forge.quest.QuestUtil;
import forge.screens.LaunchScreen; import forge.screens.LaunchScreen;
import forge.screens.LoadingOverlay; import forge.screens.LoadingOverlay;
@@ -47,7 +48,7 @@ public class ConquestMapScreen extends LaunchScreen {
} }
public void update() { public void update() {
setHeaderCaption(FModel.getConquest().getName() + "\n" + FModel.getConquest().getCurrentPlane());
} }
@Override @Override

View File

@@ -40,6 +40,10 @@ public class ConquestController {
return model == null ? null : model.getName(); return model == null ? null : model.getName();
} }
public String getCurrentPlane() {
return model == null ? null : model.getCurrentPlane().getName();
}
public CardPool getCardPool() { public CardPool getCardPool() {
return cardPool; return cardPool;
} }

View File

@@ -55,7 +55,13 @@ public final class ConquestData {
difficulty = difficulty0; difficulty = difficulty0;
startingPlane = startingPlane0; startingPlane = startingPlane0;
currentPlane = startingPlane0; currentPlane = startingPlane0;
commanders.add(new ConquestCommander(startingCommander0, startingPlane.getCardPool())); addCommander(startingCommander0);
}
private void addCommander(PaperCard card) {
ConquestCommander commander = new ConquestCommander(card, currentPlane.getCardPool());
commanders.add(commander);
decks.put(commander.getDeck().getName(), commander.getDeck());
} }
public String getName() { public String getName() {