public void LoseBattle() { window.SetActive(false); string title = "You lose"; string desc = "You lose"; popupmanager.GetComponent <PopupSpawner>().PopEvent(title, desc); ManagerScenes.LoadScene(ManagerScenes.scenes.Lose); }
void Update() { //Debug.Log(pm);//NULL resources.sailmode = current; pm.pointcalc(pirates); if (pirates.Count == 0) { ManagerScenes.LoadScene(ManagerScenes.scenes.Lose); } life.text = "Your ship has " + HullPoint + "/" + MaxHull + " life points"; }
public void StartButton() { Time.timeScale = 1; gameObject.SetActive(false); SoundManager.Stop("YouAreAPirate"); //Debug.Log("Stopped music..."); ManagerScenes.LoadScene(ManagerScenes.scenes.Game); //Debug.Log("Loaded scene..."); SoundManager.Play("Sea"); //Debug.Log("Started music..."); }
public void OnPointerClick(PointerEventData eventData) { if (ManagerScenes.lastScene == 0) { ManagerScenes.LoadScenes(i_indexLoad); } else { ManagerScenes.LoadScenes(ManagerScenes.lastScene); } }
//delete one of the scripts if two or more exist private void Awake() { if (managescenes == null) { managescenes = this; DontDestroyOnLoad(gameObject); } else { Destroy(gameObject); } }
// Update is called once per frame void Update() { if (Input.GetKeyDown(KeyCode.C)) { ManagerScenes.lastScene = SceneManager.GetActiveScene().buildIndex; ManagerScenes.LoadScenes(1); } if (Input.GetKeyDown(KeyCode.R)) { ManagerScenes.LoadScenes(2); } if (Input.GetKeyDown(KeyCode.Space)) { StartCoroutine(CountBack()); } }
public void d() { ManagerScenes.LoadScene(ManagerScenes.scenes.Game); }
private void OnMouseDown() { ManagerScenes.LoadScenes(index); }
void Restart() { ManagerScenes.LoadScenes(1); }