// ----------------------------------------------------------------------------------- // // ----------------------------------------------------------------------------------- void Awake() { onStateChanged += OnStateChanged; language = configuration.defaultLanguage; SceneManager.LoadScene("GUI", LoadSceneMode.Additive); DontDestroyOnLoad(this.gameObject); }
// ------------------------------------------------------------------------------- // GetAllTemplates // ------------------------------------------------------------------------------- static public List <LanguageTemplate> GetAllTemplates() { InstantiateLibrary(); LanguageTemplate[] tmpl = new LanguageTemplate[Dict.Count]; Dict.Values.CopyTo(tmpl, 0); return(tmpl.ToList()); }
// ----------------------------------------------------------------------------------- // OnLangChanged // ----------------------------------------------------------------------------------- public void OnLangChanged() { LanguageTemplate tmpl = LanguageLibrary.GetTemplate(languageDropdown.options[languageDropdown.value].text); Obj.GetGame.language = tmpl; Show(); }