//Wenn auf Impressum geklickt wurde public void OnImpressum(bool clicked) { if (clicked) { Impressummenue.SetActive(clicked); Hauptmenue.SetActive(!clicked); } else { Impressummenue.SetActive(clicked); Hauptmenue.SetActive(!clicked); } }
public void OnZuruecksetzen(bool clicked) { if (clicked) { float musik = PlayerPrefs.GetFloat("MusicVolumen"); float effekt = PlayerPrefs.GetFloat("EffektVolumen"); PlayerPrefs.DeleteAll(); PlayerPrefs.SetFloat("MusicVolumen", musik); PlayerPrefs.SetFloat("EffektVolumen", effekt); Optionenmenue.SetActive(!clicked); Hauptmenue.SetActive(clicked); Impressummenue.SetActive(!clicked); Levelmenue.SetActive(!clicked); SceneManager.LoadScene(0); } }
//Wenn auf Obtionen geklickt wurde public void OnOptionen(bool clicked) { if (clicked) { Optionenmenue.SetActive(clicked); //wird das OptionsmenuePanel sichtbar gemacht Hauptmenue.SetActive(!clicked); //wird das HauptmenuePanel unsichtbar gemacht Impressummenue.SetActive(!clicked); Levelmenue.SetActive(!clicked); } else { Optionenmenue.SetActive(clicked); Hauptmenue.SetActive(!clicked); Impressummenue.SetActive(clicked); Levelmenue.SetActive(clicked); } }
//Wenn auf Level geklickt wurde public void OnLevel(bool clicked) { if (clicked) { Levelmenue.SetActive(clicked); Hauptmenue.SetActive(!clicked); Optionenmenue.SetActive(!clicked); Impressummenue.SetActive(!clicked); } else { Levelmenue.SetActive(clicked); Hauptmenue.SetActive(!clicked); Optionenmenue.SetActive(clicked); Impressummenue.SetActive(clicked); } }