直接调用android自带的SDK
#if UNITY_ANDROID && !UNITY_EDITOR AndroidJavaClass localeClass = new AndroidJavaClass("java/util/Locale"); AndroidJavaObject defaultLocale = localeClass.CallStatic("getDefault"); AndroidJavaObject usLocale = localeClass.GetStatic ("US"); string systemLanguage = defaultLocale.Call ("getDisplayLanguage", usLocale); Debug.Log("systemLanguage:" + systemLanguage); SystemLanguage code; try { code = (SystemLanguage)Enum.Parse(typeof(SystemLanguage), systemLanguage); } catch { code = SystemLanguage.Unknown; }#else SystemLanguage code = Application.systemLanguage; #endif