Menue scene mit funktionierenden Buttons und Start Script für den PlayerController
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
//Oliver
|
||||
using UnityEngine;
|
||||
using UnityEngine.UI;
|
||||
|
||||
public class PlayerController : MonoBehaviour
|
||||
{
|
||||
private int speed;
|
||||
Vector3 position = Vector3.zero;
|
||||
private Text score;
|
||||
private int points;
|
||||
Rigidbody rb;
|
||||
// Start is called once before the first execution of Update after the MonoBehaviour is created
|
||||
void Start()
|
||||
{
|
||||
rb = GetComponent<Rigidbody>;
|
||||
}
|
||||
|
||||
// Update is called once per frame
|
||||
void Update()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,2 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 5e857b6f5c4484c449d9e726f2fc5d36
|
||||
@@ -0,0 +1,26 @@
|
||||
// Oliver
|
||||
using UnityEngine;
|
||||
using UnityEngine.SceneManagement;
|
||||
using UnityEngine.UI;
|
||||
|
||||
public class UIHandler : MonoBehaviour
|
||||
{
|
||||
public void Start()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public void ChangeScene(string sceneName)
|
||||
{
|
||||
SceneManager.LoadScene(sceneName);
|
||||
}
|
||||
|
||||
public void Quit()
|
||||
{
|
||||
#if UNITY_EDITOR
|
||||
UnityEditor.EditorApplication.isPlaying = false;
|
||||
#else
|
||||
Application.Quit();
|
||||
#endif
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,2 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 039d8264ac1c9ed42a3657361d73ced5
|
||||
Reference in New Issue
Block a user