public void OnButtonClick(string ButtonName) { SoundController.Static.PlayClickSound(); switch (ButtonName) { case "Back": ControlSelection.SetActive(false); LevelSelection.SetActive(true); break; case "Accel": selectedMode = controls.tilt; LoadingMenu.SetActive(true); ControlSelection.SetActive(false); break; case "Button": selectedMode = controls.buttons; LoadingMenu.SetActive(true); ControlSelection.SetActive(false); break; } }
static void CreateLoadingScreen() { Thread t = new Thread(() => { LoadingMenu lS = new LoadingMenu(); lS.Timer1TickAction += () => { if (!Parameter.IsLoadingGameAssets) { lS.Close(); } }; lS.ShowDialog(); }); t.IsBackground = false; t.Start(); }
public void LoadScene(int idx) { StartCoroutine(LoadSceneCor(idx)); LoadingMenu.SetActive(true); }
// Start is called before the first frame update void Start() { MainMenu.SetActive(true); LevelSelection.SetActive(false); LoadingMenu.SetActive(false); }