private void Awake() { Init(); foreach (var langEnable in ApplicationManager.instance.appSettings.langAppEnable) { var langText = LoadLangText(langEnable.code); langTextList.Add(langText); } var commonText = LoadCommonLangText(); langTextList.Add(commonText); _currentLang = ApplicationManager.instance.appSettings.defaultLanguage; }
/// <summary> /// Called whenever the OnLangChange event of the TextManager is triggered. Sets the text to its current lang value. /// </summary> /// <param name="lang"></param> private void OnLangChange(LangApp lang) { SetText(); }
/// <summary> /// Sets the current language to the default language of the application as described in the game settings. /// </summary> public void SetDefaultLang() { currentLang = ApplicationManager.instance.appSettings.defaultLanguage; }
public bool Equals(LangApp other) { return(code == other.code && name == other.name && color == other.color); }