Добавлен максимальный счёт с сохранением
This commit is contained in:
@ -1,10 +1,18 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using TMPro;
|
||||
using UnityEngine;
|
||||
using UnityEngine.SceneManagement;
|
||||
|
||||
public class MenuScript : MonoBehaviour
|
||||
{
|
||||
[SerializeField] private int _BestScore;
|
||||
[SerializeField] private TextMeshProUGUI _TextScore;
|
||||
|
||||
private void OnEnable()
|
||||
{
|
||||
_BestScore = PlayerPrefs.GetInt("Best score");
|
||||
_TextScore.text = "Лучший счёт - " + _BestScore;
|
||||
}
|
||||
|
||||
// Start is called before the first frame update
|
||||
public void RestartGame()
|
||||
{
|
||||
|
Reference in New Issue
Block a user