Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions forge-gui-mobile/src/forge/adventure/data/ConfigData.java
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ public class ConfigData {
public String[] allowedJumpstart;
public String defaultBasicLandSet = "JMP";
public boolean enableGeneticAI = true;
public String chaosDeckFormat;
public boolean usePriceListPrices = true;

}
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,8 @@ public Array<String> getModes() {
}

public boolean isCommanderLike() {
return this == Commander || this == CommanderPrecon;
if (this == Commander || this == CommanderPrecon) return true;
return this == Chaos && "Commander".equalsIgnoreCase(Config.instance().getConfigData().chaosDeckFormat);
}

public boolean usesFolderDeckPicker() {
Expand Down
4 changes: 4 additions & 0 deletions forge-gui-mobile/src/forge/adventure/util/CardUtil.java
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
import forge.deck.DeckgenUtil;
import forge.deck.io.DeckSerializer;
import forge.game.GameFormat;
import forge.game.GameType;
import forge.item.BoosterPack;
import forge.item.PaperCard;
import forge.item.PaperCardPredicates;
Expand Down Expand Up @@ -750,6 +751,9 @@ public static Deck getDeck(String path, boolean forAI, boolean isFantasyMode, St
}

if (forAI && (isFantasyMode || useGeneticAI)) {
if (isFantasyMode && "Commander".equalsIgnoreCase(Config.instance().getConfigData().chaosDeckFormat)) {
return DeckgenUtil.generateCommanderDeck(true, GameType.Commander);
}
return DeckgenUtil.getRandomOrPreconOrThemeDeck(colors, forAI, isTheme, useGeneticAI);
}

Expand Down
4 changes: 4 additions & 0 deletions forge-gui-mobile/src/forge/adventure/util/Config.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import forge.deck.Deck;
import forge.deck.DeckProxy;
import forge.deck.DeckgenUtil;
import forge.game.GameType;
import forge.gui.GuiBase;
import forge.item.PaperCard;
import forge.localinstance.properties.ForgeConstants;
Expand Down Expand Up @@ -257,6 +258,9 @@ public Deck starterDeck(ColorSet color, DifficultyData difficultyData, Adventure
}
}
case Chaos:
if ("Commander".equalsIgnoreCase(configData.chaosDeckFormat)) {
return DeckgenUtil.generateCommanderDeck(false, GameType.Commander);
}
return DeckgenUtil.getRandomOrPreconOrThemeDeck("", false, false, false, configData.allowedEditions);
case Custom:
return DeckProxy.getAllCustomStarterDecks().get(index).getDeck();
Expand Down
1 change: 1 addition & 0 deletions forge-gui/res/adventure/Realm of Legends/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,7 @@
"CN2"
],
"usePriceListPrices": false,
"chaosDeckFormat": "Commander",
"difficulties": [
{
"name": "Easy",
Expand Down