StartMenu!
This commit is contained in:
26
Assets/Scripts/StartMenu/StartMenuManager.cs
Normal file
26
Assets/Scripts/StartMenu/StartMenuManager.cs
Normal file
@@ -0,0 +1,26 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
namespace Ichni.StartMenu
|
||||
{
|
||||
public class StartMenuManager : MonoBehaviour
|
||||
{
|
||||
public static StartMenuManager instance;
|
||||
public StartPage startPage;
|
||||
public CreateEmptyProjectPage createEmptyProjectPage;
|
||||
|
||||
private void Awake()
|
||||
{
|
||||
if (instance == null)
|
||||
{
|
||||
instance = this;
|
||||
DontDestroyOnLoad(gameObject);
|
||||
}
|
||||
else if (instance != this)
|
||||
{
|
||||
Destroy(gameObject);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user