mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-17 19:28:01 +00:00
- Additional changes related to the previous commit.
This commit is contained in:
@@ -63,6 +63,12 @@ public final class GamePlayerUtil {
|
|||||||
String profile = "";
|
String profile = "";
|
||||||
if (profileOverride.isEmpty()) {
|
if (profileOverride.isEmpty()) {
|
||||||
String lastProfileChosen = FModel.getPreferences().getPref(FPref.UI_CURRENT_AI_PROFILE);
|
String lastProfileChosen = FModel.getPreferences().getPref(FPref.UI_CURRENT_AI_PROFILE);
|
||||||
|
if (!AiProfileUtil.getProfilesDisplayList().contains(lastProfileChosen)) {
|
||||||
|
System.out.println("[AI Preferences] Unknown profile " + lastProfileChosen + " was requested, resetting to default.");
|
||||||
|
lastProfileChosen = "Default";
|
||||||
|
FModel.getPreferences().setPref(FPref.UI_CURRENT_AI_PROFILE, "Default");
|
||||||
|
FModel.getPreferences().save();
|
||||||
|
}
|
||||||
player.setRotateProfileEachGame(lastProfileChosen.equals(AiProfileUtil.AI_PROFILE_RANDOM_DUEL));
|
player.setRotateProfileEachGame(lastProfileChosen.equals(AiProfileUtil.AI_PROFILE_RANDOM_DUEL));
|
||||||
if (lastProfileChosen.equals(AiProfileUtil.AI_PROFILE_RANDOM_MATCH)) {
|
if (lastProfileChosen.equals(AiProfileUtil.AI_PROFILE_RANDOM_MATCH)) {
|
||||||
lastProfileChosen = AiProfileUtil.getRandomProfile();
|
lastProfileChosen = AiProfileUtil.getRandomProfile();
|
||||||
|
|||||||
Reference in New Issue
Block a user