public static void InitializeTheGame() { // DEBUG : NameOfThePlayer = "Akuumy"; Lang.DefineLanguage(System.IO.Directory.GetFiles(".", "lang.fr.xml", System.IO.SearchOption.AllDirectories)[0], "French"); }
private string _ui_currenthp; // HP translated #endregion #region METHODS private void Awake() { // DEBUG: Lang.DefineLanguage(System.IO.Directory.GetFiles(".", "lang.fr.xml", System.IO.SearchOption.AllDirectories)[0], "French"); _txtHealthValue = GameObject.Find("txtHealthValue").GetComponent <UnityEngine.UI.Text>(); _ui_currenthp = Lang.GetString("ui.currenthp"); }
// TODO: Ajouter toutes les autres vérifications et initialisations private void Awake() { // Language string[] s = System.IO.Directory.GetFiles(".", "lang.fr.xml", System.IO.SearchOption.AllDirectories); Lang.DefineLanguage(s[0], Application.systemLanguage.ToString()); // Init all texts mainMenuTexts[0].text = Lang.GetString("mainmenu.startbutton"); }
private UnityEngine.UI.Text _txtCanPerformAnAction; // Le texte des actions que le joueur peut faire #endregion #region METHODS private void Awake() { // DEBUG: Lang.DefineLanguage(System.IO.Directory.GetFiles(".", "lang.fr.xml", System.IO.SearchOption.AllDirectories)[0], "French"); // Init _rb = GetComponent <Rigidbody>(); screenPosForRayCast = Camera.main.WorldToScreenPoint(gameObject.transform.position); _txtCanPerformAnAction = GameObject.Find("txtCanPerformAnAction").GetComponent <UnityEngine.UI.Text>(); }
void Awake() { // DEBUG: Initialize stats #if UNITY_EDITOR Lang.DefineLanguage(System.IO.Directory.GetFiles(".", "lang.fr.xml", System.IO.SearchOption.AllDirectories)[0], "French"); InitPlayerStats.NewGameInitStats(100); #endif Hunger = 100; Thirst = 100; _pnlCurrentBuffs = GameObject.Find("pnlCurrentBuffs"); _txtHungerValue = GameObject.Find("txtHungerValue").GetComponent <Text>(); _txtThirstValue = GameObject.Find("txtThirstValue").GetComponent <Text>(); GameObject.Find("txtHealthValue").GetComponent <Text>().text = CurrentHP + "/" + MaxHP + " " + Lang.GetString("ui.currenthp"); InvokeRepeating("LoweringHunger", 0, 2); InvokeRepeating("LoweringThirst", 0, 1); }