From fff60a7c1d7f547bff89aefe8fa415f02f630213 Mon Sep 17 00:00:00 2001 From: Evan Debenham Date: Thu, 4 Feb 2016 19:47:26 -0500 Subject: [PATCH] v0.3.4: only reviewed languages can be default languages now --- .../shatteredpixeldungeon/ShatteredPixelDungeon.java | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/com/shatteredpixel/shatteredpixeldungeon/ShatteredPixelDungeon.java b/src/com/shatteredpixel/shatteredpixeldungeon/ShatteredPixelDungeon.java index ccbb190a4..163fcd6ec 100644 --- a/src/com/shatteredpixel/shatteredpixeldungeon/ShatteredPixelDungeon.java +++ b/src/com/shatteredpixel/shatteredpixeldungeon/ShatteredPixelDungeon.java @@ -346,7 +346,13 @@ public class ShatteredPixelDungeon extends Game { public static Messages.Languages language() { String code = Preferences.INSTANCE.getString(Preferences.KEY_LANG, null); - if (code == null) return Messages.Languages.matchLocale(Locale.getDefault()); + if (code == null){ + Messages.Languages lang = Messages.Languages.matchLocale(Locale.getDefault()); + if (lang.status() == Messages.Languages.Status.REVIEWED) + return lang; + else + return Messages.Languages.ENGLISH; + } else return Messages.Languages.matchCode(code); }