Skip to content
Snippets Groups Projects
Commit 27664489 authored by Julius Fredrik Einum's avatar Julius Fredrik Einum
Browse files

Added namespace to endScreen

parent 43871359
No related branches found
No related tags found
1 merge request!79Ruud1
......@@ -3,31 +3,35 @@ using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;
public class EndScreen : MonoBehaviour
{
public void Start()
{
Time.timeScale = 0;
GameObject menu = GameObject.Find("PlayerMenu(Clone)");
if (menu != null) {
Destroy(menu.gameObject);
namespace BigSock.UI
{
public class EndScreen : MonoBehaviour
{
public void Start()
{
Time.timeScale = 0;
GameObject menu = GameObject.Find("PlayerMenu(Clone)");
if (menu != null)
{
Destroy(menu.gameObject);
}
}
}
public void OnDestroy()
{
Time.timeScale = 1;
}
public void OnDestroy()
{
Time.timeScale = 1;
}
public void GiveUp()
{
Application.Quit();
}
public void GiveUp()
{
Application.Quit();
}
public void TryAgain()
{
Destroy(gameObject);
SceneManager.LoadScene("MainMenu");
public void TryAgain()
{
Destroy(gameObject);
SceneManager.LoadScene("MainMenu");
}
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment