IEnumerator Update_Jeton() { yield return(new WaitForSeconds(2)); if (save.Get_jetons() != 0) { save.Set_jetons(save.Get_jetons() - 1); if (save.Get_langue() == 0) { jet_text_1.text = "Il vous en reste : " + save.Get_jetons(); } else { jet_text_1.text = "You have " + save.Get_jetons() + " left."; } jet_text_2.text = Random_aug(); jet_text_2.color = Nice_color(); } if (save.Get_jetons() != 0) // s'il reste des jetons { StartCoroutine(Update_Jeton()); } else { jet_btn.gameObject.SetActive(true); Display_Dip(); } }
void Start() { save = FindObjectOfType <Sauvegarde>(); if (Application.platform == RuntimePlatform.Android) { path = Path.Combine(Application.persistentDataPath, fileName); } else { path = Path.Combine(Application.streamingAssetsPath, fileName); } if (File.Exists(path) == false) { Save_Highest(); } else { ChargefromFile(); } NbGamePlayed++; float now = save.Get_assos() + 2 * save.Get_etude() + save.Get_sociabilite(); if (save.Get_langue() == 0) { text.text = " Statistics : \n\n\n "; } else { text.text = " Statistiques : \n\n\n "; } if (now > HighestScore) { HighestScore = now; if (save.Get_langue() == 0) { text.text = text.text + " Félicitations ! Tu as battu ton meilleur score\n"; } else { text.text = text.text + " Congratulations ! You've beated your Highest Score :D \n"; } } Display_text(); Save_Highest(); }
void Start() { Result.gameObject.SetActive(false); save = FindObjectOfType <Sauvegarde>(); if (save.Get_langue() == 1) { GameObject.Find("Stop Dices").GetComponentInChildren <Text>().text = "Stop dices"; } isTurning = true; }
void Display_text() { if (save.Get_langue() == 0) { text.text = text.text + "\nHighest Score : " + HighestScore + "\n\n Number of Game played : " + NbGamePlayed; } else { text.text = text.text + "\nMeilleur Score : " + HighestScore + "\n\n Nombre de parties jouées : " + NbGamePlayed; } }
public void Start() { save = FindObjectOfType <Sauvegarde>(); langue = save.Get_langue(); if (langue == 0) { IniFrench(); } else if (langue == 1) { IniEnglish(); } }
void Start() { save = FindObjectOfType <Sauvegarde>(); bars = FindObjectOfType <Bars>(); jet = save.Get_jetons(); if (save.Get_langue() == 0) { diplome_Titre.text = "Ton Diplome : "; diplome_text.text = "Name : " + save.Get_player() + "\nSection : " + save.Get_section() + "\nMajeure : " + save.Get_majeure() + "\nTa destination : " + save.Get_destination() + "\nTes associations : \n" + Get_sub_assos(); if (save.Get_bde()) { diplome_text.text = diplome_text.text + "Tu as fais partie du BDE\n"; } //job_titre.text = "Les métiers qui te correspondent sont : "; //job_text.text = "A completer !! :D"; menu_btn.text = "Retourner au Menu"; jet_title.text = "Vous avez gagné " + jet + " jetons !"; jet_text_1.text = "Il vous en reste : " + save.Get_jetons(); StartCoroutine(Update_Jeton()); } else { diplome_Titre.text = "Your Diploma : "; diplome_text.text = "Section : " + save.Get_section() + "\nMajeure : " + save.Get_majeure() + "\nYour destination : " + save.Get_destination() + "\nYour associations : \n" + Get_sub_assos(); if (save.Get_bde()) { diplome_text.text = diplome_text.text + "\nYou've been a part of the Student Association.\n"; } job_titre.text = "Jobs that would fit you : "; job_text.text = "A completer !! :D"; menu_btn.text = " Go to the Main Menu"; jet_title.text = "You have earned " + jet + " chips !"; jet_text_1.text = "You have " + save.Get_jetons() + " left."; StartCoroutine(Update_Jeton()); } }
// Update is called once per frame public void Button_clicked(int i) { if (i < 3) { if (save.Get_langue() == 0) { text.text = "Vous ne faites plus parti de " + save.Get_Tab_assos(i); } else { text.text = "You are no longer a part of " + save.Get_Tab_assos(i); } save.Set_Tab_assos(i, "none"); button1.gameObject.SetActive(false); button2.gameObject.SetActive(false); button3.gameObject.SetActive(false); button4.GetComponentInChildren <Text>().text = "Continue"; if (i == 0) { FindObjectOfType <AssosManager>().choixAssos2.text = ""; } else if (i == 1) { FindObjectOfType <AssosManager>().choixAssos3.text = ""; } else if (i == 2) { FindObjectOfType <AssosManager>().choixAssos4.text = ""; } } else { canvas.SetActive(true); canvas_suppress.SetActive(false); } }
public void Initialize() { button1.gameObject.SetActive(true); button2.gameObject.SetActive(true); button3.gameObject.SetActive(true); canvas_suppress.SetActive(true); canvas.SetActive(false); save = FindObjectOfType <Sauvegarde>(); if (save.Get_langue() == 0) { text.text = "Tu es déjà inscrit dans 3 associations.\n Laquelle veux-tu supprimer ? "; } else { text.text = "You're already enrolled in 3 associations.\n Which one do you want to get out of ?"; } button1.GetComponentInChildren <Text>().text = save.Get_Tab_assos(0); button2.GetComponentInChildren <Text>().text = save.Get_Tab_assos(1); button3.GetComponentInChildren <Text>().text = save.Get_Tab_assos(2); }
public void Start() { save = FindObjectOfType <Sauvegarde>(); langue = save.Get_langue(); choix.SetActive(false); seul.SetActive(false); encadre.SetActive(false); //Debug.Log("langue " + langue); if (langue == 0) { encadre.SetActive(true); returnBtn.SetActive(false); } else if (langue == 1) { choix.SetActive(true); } }
public void Toogle_lex() { if (save.Get_langue() == 0) { text_lex.text = "Lexique:" + "\n\nWEI: Week - end d'intégration" + "\n\nPOD: Soirée étudiante " + "\n\nRezal: Venez jouer aux jeux vidéos toute la nuit, au programme: Lol, Overwatch, Team Fortress et bien d'autres..." + "\n\nAkii Partie : Venez découvrir la culture asiatique lors d'un événement nocturne organisé par Asian Efrei. Au programme : Karaoké, jeux traditionnels, origami..." + "\n\nInternational Day : Une journée dédiée à la culture des différents pays.\n" + "\n\nBDE : Bureau des étudiants" + "\n\nDE : Devoir écrit" + "\n\nCE : Contrôle écrit" + "\n\nPFE : Projet de fin d'études" + "\n\nIweek : Semaine d'accueil d'étrangers à l'EFREI. Faire découvrir et visiter Paris." + "\n\nFab lab : Laboratoire de fabrication" + "\n\nTalent day : Forum des entreprises à l'EFREI." + "\n\nInnovation day : Journée des projets étudiants" + "\n\nPrintemps des entrepreneurs : Recueil d'avis de professionnels sur des projets d'entreuprenariats des étudiants."; } else { text_lex.text = "Lexique:" + "\n\nWEI: Intégration Weekend" + "\n\nPOD: Student Party" + "\n\nRezal: Come play video games all night, on the program: LoL, Overwatch, Team Fortress and many more ..." + "\n\nAkii Partie : Come and discover Asian culture at a night event organized by Asian Efrei, featuring Karaoke, traditional games, origami ..." + "\n\nInternational Day : A day dedicated to the culture of foreign countries. " + "\n\nBDE : Student Services Office" + "\n\nDE : Written exam" + "\n\nCE : Written test" + "\n\nPFE : End of study project" + "\n\nIweek : Welcome week for foreigners at EFREI. Discovery and visit of Paris for the foreigners students." + "\n\nFab lab : Fabrication laboratory" + "\n\nTalent day : Fair of companies at EFREI." + "\n\nInnovation day : day of presentation of student's project" + "\n\nPrintemps des entrepreneurs : A collection of professional opinions on student entrepreneurship projects."; } }
void Start() { dataController = FindObjectOfType <DataController>(); save = FindObjectOfType <Sauvegarde>(); if (save.Get_langue() == 0) { truebutton.GetComponentInChildren <Text>().text = "Vrai"; falsebutton.GetComponentInChildren <Text>().text = "Faux"; } currentRoundData = dataController.GetCurrentRoundData(); // Ask the DataController for the data for the current round. At the moment, we only have one round - but we could extend this questionPool = currentRoundData.questions; // Take a copy of the questions so we could shuffle the pool or drop questions from it without affecting the original RoundData object timeRemaining = currentRoundData.timeLimitInSeconds; // Set the time limit for this round based on the RoundData object UpdateTimeRemainingDisplay(); playerScore = 0; nb_questionsasked = 1; questionIndex = RandomizetheQuestion(alreadytook); ShowQuestion(); isRoundActive = true; }
public IEnumerator Choice() { yield return(1); iTween.Pause(); CaseDisplay.SetActive(true); button.gameObject.SetActive(false); if (save.Get_langue() == 0) { text.text = "Choisissez votre chemin"; btn1_dilemme.GetComponentInChildren <Text>().text = "Gauche"; btn2_dilemme.GetComponentInChildren <Text>().text = "Droite"; } else { text.text = "Choose your path"; btn1_dilemme.GetComponentInChildren <Text>().text = "Left"; btn2_dilemme.GetComponentInChildren <Text>().text = "Right"; } btn1_dilemme.gameObject.SetActive(true); btn2_dilemme.gameObject.SetActive(true); }
public void Start() { save = FindObjectOfType <Sauvegarde>(); if (save.Get_counter() == 24 || save.Get_counter() == 84) { Titletext.text = "Projet Voltaire"; Rulestext.text = "Une phrase est affichée.\n Répondez VRAI si elle ne contient PAS de faute.\n Répondez FAUX si elle contient une faute."; } else if (save.Get_counter() == 91) { Titletext.text = "TOEIC"; Rulestext.text = "A sentence is displayed.\n Answer TRUE if it does NOT contains a fault.\n Answer FALSE if it contains a fault."; } else { if (save.Get_counter() == 4) { Titletext.text = "Concours Puissance Alpha"; } else if (save.Get_counter() == 19) { Titletext.text = "CE L1"; } else if (save.Get_counter() == 34) { Titletext.text = "DE L1"; } else if (save.Get_counter() == 45) { Titletext.text = "DE L2"; } else if (save.Get_counter() == 51) { Titletext.text = "CE L3"; } else if (save.Get_counter() == 54) { Titletext.text = "CE L3"; } else if (save.Get_counter() == 63) { Titletext.text = "DE L3"; } else if (save.Get_counter() == 79) { Titletext.text = "DE M1"; } else if (save.Get_counter() == 98) { Titletext.text = "DE M2"; } if (save.Get_langue() == 0) { Rulestext.text = "Une affirmation vous est affichée.\n Dites si elle est VRAI ou FAUSSE."; } else { Rulestext.text = "An affirmation is shown.\n Indicate if it is TRUE or FALSE."; } } }
void Start() { save = FindObjectOfType <Sauvegarde>(); switch (save.Get_counter()) { case 4: filename = "data_concours.txt"; break; case 19: if (save.Get_langue() == 0) { filename = "data_L1.txt"; } else { filename = "data_L1_E.txt"; } break; case 24: filename = "Projet_Voltaire.txt"; break; case 34: if (save.Get_langue() == 0) { filename = "data_L1.txt"; } else { filename = "data_L1_E.txt"; } break; case 45: if (save.Get_langue() == 0) { filename = "data_L2.txt"; } else { filename = "data_L2_E.txt"; } break; case 51: if (save.Get_langue() == 0) { filename = "data_L3.txt"; } else { filename = "data_L3_E.txt"; } break; case 54: if (save.Get_langue() == 0) { filename = "data_L3.txt"; } else { filename = "data_L3_E.txt"; } break; case 63: if (save.Get_langue() == 0) { filename = "data_L3.txt"; } else { filename = "data_L3_E.txt"; } break; case 79: if (save.Get_langue() == 0) { filename = "data_M1.txt"; } else { filename = "data_M1_E.txt"; } break; case 84: filename = "Projet_Voltaire.txt"; break; case 91: filename = "TOEIC.txt"; break; case 98: if (save.Get_langue() == 0) { filename = "data_M2.txt"; } else { filename = "data_M2_E.txt"; } break; default: filename = "data_concours.txt"; break; } }
private void ShowResults() { if (playerScore >= threshold) { if (save.Get_langue() == 0) { resultsDisplay.text = "Félicitations, tu as réussis l'examen !"; endbutton.text = "Continuer"; } else { resultsDisplay.text = "Congratulations, you've suceeded the exam !"; endbutton.text = "Continue"; } } else if (dataController.Get_attempt() == 2) { if (save.Get_langue() == 0) { resultsDisplay.text = "Tu as raté ton examen pour la seconde fois ! Tu n'auras aucun point."; endbutton.text = "Continuer"; } else { resultsDisplay.text = "You've failed the exam for the second time ! You'll not earn any point."; endbutton.text = "Continue"; } dataController.Set_attempt(dataController.Get_attempt() + 1); } else { dataController.Set_attempt(dataController.Get_attempt() + 1); if (save.Get_langue() == 0) { if (playerScore < 30) { resultsDisplay.text = "Oh non ! Ton score est beaucoup trop bas.\n - 10 points Etudes ! \nRetente ta chance !"; FindObjectOfType <Bars>().DealEtudeMinus(10f); } else { resultsDisplay.text = "Oh non ! Ton score est trop bas pour continuer. \nRetente ta chance !"; } endbutton.text = "Aller au début"; } else { if (playerScore < 30) { resultsDisplay.text = "No.. Your score is way too low to continue.\n - 10 points Study !\nTry again !"; FindObjectOfType <Bars>().DealEtudeMinus(10f); } else { resultsDisplay.text = "No.. Your score is too low to continue. Try again !"; } endbutton.text = "Restart the quizz"; } Debug.Log("attempt : " + dataController.Get_attempt()); } }