细节调整
This commit is contained in:
1 parent
dd08f916eb
commit
4347a8eeba
48 files changed
+1855
-400
No files matched your search
@@ -1,6 +1,9 @@
|
||||
using Mapbox.Examples;
|
||||
using Assets.Scripts;
|
||||
using Assets.Scripts.Devices.Ant;
|
||||
using Mapbox.Examples;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using System.Threading.Tasks;
|
||||
using UnityEngine;
|
||||
using UnityEngine.UI;
|
||||
|
||||
@@ -11,17 +14,23 @@ public class MainController : MonoBehaviour
|
||||
private void Awake()
|
||||
{
|
||||
Version = this.transform.Find("GameObject").Find("Version").GetComponent<Text>();
|
||||
Version.text = "Version:"+App.AppVersion;
|
||||
Version.text = "V"+App.AppVersion;
|
||||
|
||||
AntConnector.Instance();
|
||||
}
|
||||
|
||||
// Start is called before the first frame update
|
||||
void Start()
|
||||
async void Start()
|
||||
{
|
||||
UIManager.Instance.Root = root;
|
||||
UIManager.Instance.MainPanel = this.transform.Find("Panel").GetComponent<PFUIPanel>();
|
||||
UIManager.Instance.ModalsPanel = this.transform.Find("ModalPanel").GetComponent<PFUIPanel>();
|
||||
|
||||
if (App.CurrentUser == null)
|
||||
{
|
||||
await Login();
|
||||
}
|
||||
|
||||
//MainMenu.transform.Find("Home").GetComponent<Button>().onClick.AddListener(() =>
|
||||
//{
|
||||
// UIManager.ShowHomePanel();
|
||||
@@ -47,4 +56,15 @@ public class MainController : MonoBehaviour
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
private async Task Login()
|
||||
{
|
||||
var result = await ConfigHelper.userApi.Login("13115011550", "laozhong", "");
|
||||
App.CurrentUser = result.data;
|
||||
}
|
||||
|
||||
private void OnApplicationQuit()
|
||||
{
|
||||
AntConnector.Instance().Dispose();
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user