diff --git a/src/main/java/emu/grasscutter/Grasscutter.java b/src/main/java/emu/grasscutter/Grasscutter.java index 823633c4f..89c4d8a26 100644 --- a/src/main/java/emu/grasscutter/Grasscutter.java +++ b/src/main/java/emu/grasscutter/Grasscutter.java @@ -149,7 +149,13 @@ public final class Grasscutter { public static void loadLanguage() { var locale = config.LocaleLanguage; - language = Language.getLanguage(locale.toLanguageTag()); + String languageTag = locale.toLanguageTag(); + if (languageTag.equals("und")) { + Grasscutter.getLogger().error("Illegal locale language, using en-US instead."); + language = Language.getLanguage("en-US"); + } else { + language = Language.getLanguage(languageTag); + } } public static void saveConfig() {