- using System.Collections;
- using System.Collections.Generic;
- using UnityEngine;
- using UnityEngine.UI;
- using TMPro;
- using UnityEngine.SceneManagement;
- public class MainMenuBehaviour : MonoBehaviour
- {
- [SerializeField] private Texture2D cursorTexture;
- private Vector2 cursorHotspot;
- private void Start()
- {
- Cursor.SetCursor(cursorTexture, cursorHotspot, CursorMode.ForceSoftware);
- Cursor.visible = true;
- Cursor.lockState = CursorLockMode.None;
- }
-
- public void Play()
- {
- SceneManager.LoadScene(2);
- Cursor.visible = false;
- Cursor.lockState = CursorLockMode.Locked;
- }
- public void Quit()
- {
- Application.Quit();
- }
-
- public void ButtonOverlay(TMP_Text buttontext)
- {
- buttontext.color = new Color32(255, 212, 73, 255);
- }
- public void ButtonExitOverlay(TMP_Text buttontext)
- {
- buttontext.color = Color.white;
- }
- }