Advertisement
Guest User

Untitled

a guest
Oct 23rd, 2019
132
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.40 KB | None | 0 0
  1. using UnityEngine;
  2. using UnityEngine.UI;
  3. using System.Collections;
  4. using UnityEngine.SceneManagement;
  5. public class LevelManager : MonoBehaviour {
  6. public Text highScore;
  7. void Start(){
  8. if (SceneManager.GetActiveScene ().name != "Start_Menu") {
  9. highScore.text = "Score: " + PlayerPrefs.GetInt ("High Score").ToString ();
  10. }
  11. }
  12. public void LoadLevel (string name){
  13. SceneManager.LoadScene(name);
  14. }
  15. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement