Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System.Collections;
- using System.Collections.Generic;
- using UnityEngine.SceneManagement;
- using UnityEngine;
- public class TitleScreen : MonoBehaviour {
- public Texture titleTexture;
- private void Start()
- {
- }
- private void OnGUI()
- {
- GUI.DrawTexture(new Rect(0, 0, Screen.width, Screen.height), titleTexture);
- if (GUI.Button(new Rect(Screen.width / 2 - 200, Screen.height / 4, 200, 50), "Start Game"))
- {
- SceneManager.LoadScene("Scene1");
- }
- GUI.skin.label.fontSize = 20;
- GUI.skin.label.alignment = TextAnchor.UpperCenter;
- // GUI.Label(new Rect(Screen.width / 2 - 400 / 2, Screen.height / 2 - 200 / 2, 400, 200),
- // hiscores.GetComponent<Hiscores>().GetTimes());
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement