31 lines
746 B
C#
31 lines
746 B
C#
using UnityEngine;
|
|
using UnityEngine.SceneManagement;
|
|
using YooAsset;
|
|
|
|
public class Boot : MonoBehaviour
|
|
{
|
|
public GameObject MainUICanvas;
|
|
public Camera UICamera;
|
|
public EPlayMode PlayMode = EPlayMode.EditorSimulateMode;
|
|
void Awake()
|
|
{
|
|
#if UNITY_EDITOR
|
|
PlayerPrefs.DeleteAll();
|
|
#endif
|
|
Application.targetFrameRate = 60;
|
|
Application.runInBackground = true;
|
|
}
|
|
async void Start()
|
|
{
|
|
GameManager.Inst.UICamera = UICamera;
|
|
GameManager.Inst.MainUICanvas = MainUICanvas;
|
|
bool updateSuccess = await PatchManager.Inst.StartOperation(PlayMode);
|
|
if (updateSuccess)
|
|
EnterGame();
|
|
}
|
|
private void EnterGame()
|
|
{
|
|
Debug.Log("EnterGame");
|
|
}
|
|
}
|