2021-03-25 16:53:39 +08:00
|
|
|
|
using System.Collections;
|
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
|
using UnityEngine;
|
2021-03-29 09:10:59 +08:00
|
|
|
|
using UnityEngine.Events;
|
|
|
|
|
|
using UnityEngine.EventSystems;
|
2021-04-09 09:44:06 +08:00
|
|
|
|
using DG.Tweening;
|
2021-04-15 15:58:37 +08:00
|
|
|
|
using Assets.Scripts.UI.Prefab.Login;
|
2021-04-16 17:49:11 +08:00
|
|
|
|
using Newtonsoft.Json;
|
2021-03-25 16:53:39 +08:00
|
|
|
|
|
|
|
|
|
|
public class UIManager : MonoBehaviour
|
|
|
|
|
|
{
|
2021-04-09 09:44:06 +08:00
|
|
|
|
private PFUIPanel mMainPanel;
|
2021-04-15 15:58:37 +08:00
|
|
|
|
|
2021-04-09 09:44:06 +08:00
|
|
|
|
public PFUIPanel MainPanel
|
2021-03-25 16:53:39 +08:00
|
|
|
|
{
|
|
|
|
|
|
get
|
|
|
|
|
|
{
|
|
|
|
|
|
return this.mMainPanel;
|
|
|
|
|
|
}
|
|
|
|
|
|
set
|
|
|
|
|
|
{
|
|
|
|
|
|
this.mMainPanel = value;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2021-04-14 15:02:33 +08:00
|
|
|
|
public GameObject Root;
|
|
|
|
|
|
|
2021-03-29 09:10:59 +08:00
|
|
|
|
private HomeController mHomePanel;
|
|
|
|
|
|
public HomeController HomePanel
|
|
|
|
|
|
{
|
|
|
|
|
|
get
|
|
|
|
|
|
{
|
|
|
|
|
|
return this.GetPanelInstance("HomePanel", ref this.mHomePanel);
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2021-03-25 16:53:39 +08:00
|
|
|
|
private UserInfoController mUserInfoPanel;
|
|
|
|
|
|
public UserInfoController UserInfoPanel
|
|
|
|
|
|
{
|
|
|
|
|
|
get
|
|
|
|
|
|
{
|
|
|
|
|
|
return this.GetPanelInstance<UserInfoController>("UserInfoPanel", ref this.mUserInfoPanel);
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2021-03-29 09:10:59 +08:00
|
|
|
|
private DeviceController mDeviceController;
|
|
|
|
|
|
public DeviceController DevicePanel
|
|
|
|
|
|
{
|
|
|
|
|
|
get
|
|
|
|
|
|
{
|
|
|
|
|
|
return this.GetPanelInstance("DevicePanel", ref this.mDeviceController);
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
2021-04-15 15:58:37 +08:00
|
|
|
|
private SettingContoller mSettingContoller;
|
|
|
|
|
|
public SettingContoller SettingModal
|
|
|
|
|
|
{
|
|
|
|
|
|
get
|
|
|
|
|
|
{
|
|
|
|
|
|
return this.GetPanelInstance("SettingModal", ref this.mSettingContoller);
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
2021-04-16 17:49:11 +08:00
|
|
|
|
private NewsController mNewsContoller;
|
|
|
|
|
|
public NewsController NewsModal
|
|
|
|
|
|
{
|
|
|
|
|
|
get
|
|
|
|
|
|
{
|
|
|
|
|
|
return this.GetPanelInstance("NewsModal", ref this.mNewsContoller);
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
2021-03-30 14:14:24 +08:00
|
|
|
|
private MapListController mMapListController;
|
|
|
|
|
|
public MapListController MapListPanel
|
|
|
|
|
|
{
|
|
|
|
|
|
get
|
|
|
|
|
|
{
|
|
|
|
|
|
return this.GetPanelInstance("MapListPanel", ref this.mMapListController);
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
2021-03-30 14:23:41 +08:00
|
|
|
|
|
2021-04-01 11:01:05 +08:00
|
|
|
|
private MapDetailController mMapDetailController;
|
|
|
|
|
|
public MapDetailController MapDetailPanel
|
|
|
|
|
|
{
|
|
|
|
|
|
get
|
|
|
|
|
|
{
|
|
|
|
|
|
return this.GetPanelInstance("MapDetailPanel", ref this.mMapDetailController);
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2021-04-02 19:17:23 +08:00
|
|
|
|
private CyclingController mCyclingController;
|
|
|
|
|
|
public CyclingController CyclingController
|
|
|
|
|
|
{
|
|
|
|
|
|
get
|
|
|
|
|
|
{
|
|
|
|
|
|
return this.GetPanelInstance("CyclingController", ref this.mCyclingController);
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2021-03-30 14:23:41 +08:00
|
|
|
|
private EditUserController mEditUserController;
|
|
|
|
|
|
public EditUserController EditUserPanel
|
|
|
|
|
|
{
|
|
|
|
|
|
get
|
|
|
|
|
|
{
|
|
|
|
|
|
return this.GetPanelInstance("EditUserPanel", ref this.mEditUserController);
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2021-04-09 09:44:06 +08:00
|
|
|
|
private PFUIPanel mModalsPanel;
|
|
|
|
|
|
public PFUIPanel ModalsPanel
|
2021-03-30 14:23:41 +08:00
|
|
|
|
{
|
|
|
|
|
|
get
|
|
|
|
|
|
{
|
|
|
|
|
|
return this.mModalsPanel;
|
|
|
|
|
|
}
|
|
|
|
|
|
set
|
|
|
|
|
|
{
|
|
|
|
|
|
this.mModalsPanel = value;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-03-25 16:53:39 +08:00
|
|
|
|
public static UIManager Instance;
|
|
|
|
|
|
|
|
|
|
|
|
private void Awake()
|
|
|
|
|
|
{
|
|
|
|
|
|
UIManager.Instance = this;
|
2021-04-15 15:58:37 +08:00
|
|
|
|
loginRegOptions = new LoginRegOptions();
|
2021-04-16 17:49:11 +08:00
|
|
|
|
var userInfosJson = PlayerPrefs.GetString("UserInfos");
|
|
|
|
|
|
userInfos = JsonConvert.DeserializeObject<List<QUserInfo>>(userInfosJson);
|
|
|
|
|
|
if (userInfos == null) userInfos = new List<QUserInfo>();
|
|
|
|
|
|
collectDict = new Dictionary<bool, Sprite> {
|
|
|
|
|
|
{ false,Resources.Load<Sprite>("Images/p-4灰")},
|
|
|
|
|
|
{ true,Resources.Load<Sprite>("Images/p-4")},
|
|
|
|
|
|
};
|
2021-03-25 16:53:39 +08:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// Start is called before the first frame update
|
|
|
|
|
|
void Start()
|
|
|
|
|
|
{
|
2021-04-15 15:58:37 +08:00
|
|
|
|
|
2021-03-25 16:53:39 +08:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// Update is called once per frame
|
|
|
|
|
|
void Update()
|
|
|
|
|
|
{
|
2021-04-14 15:02:33 +08:00
|
|
|
|
|
2021-03-25 16:53:39 +08:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
private T GetPanelInstance<T>(string prefabName, ref T internalComponent)
|
|
|
|
|
|
{
|
|
|
|
|
|
if (internalComponent == null)
|
|
|
|
|
|
{
|
|
|
|
|
|
UnityEngine.Object @object = Resources.Load("UI/Prefab/Panel/" + prefabName);
|
|
|
|
|
|
if (@object != null)
|
|
|
|
|
|
{
|
|
|
|
|
|
GameObject gameObject = (GameObject)UnityEngine.Object.Instantiate(@object, base.transform.parent, false);
|
|
|
|
|
|
if (gameObject != null)
|
|
|
|
|
|
{
|
|
|
|
|
|
internalComponent = gameObject.GetComponent<T>();
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
return internalComponent;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2021-04-09 09:44:06 +08:00
|
|
|
|
private T GetInstance<T>(string prefabName, ref T internalComponent)
|
|
|
|
|
|
{
|
|
|
|
|
|
if (internalComponent == null)
|
|
|
|
|
|
{
|
|
|
|
|
|
UnityEngine.Object @object = Resources.Load("UI/Prefab/" + prefabName);
|
|
|
|
|
|
if (@object != null)
|
|
|
|
|
|
{
|
|
|
|
|
|
GameObject gameObject = (GameObject)UnityEngine.Object.Instantiate(@object, base.transform.parent, false);
|
|
|
|
|
|
if (gameObject != null)
|
|
|
|
|
|
{
|
|
|
|
|
|
internalComponent = gameObject.GetComponent<T>();
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
return internalComponent;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
private static PFUIPanel prePanel = null;
|
|
|
|
|
|
public static void Show(PFUIPanel panelToShow, PFUIPanel parent = null, bool modal = false)
|
2021-03-25 16:53:39 +08:00
|
|
|
|
{
|
|
|
|
|
|
if (UIManager.Instance == null || panelToShow == null)
|
|
|
|
|
|
{
|
|
|
|
|
|
return;
|
|
|
|
|
|
}
|
2021-03-30 14:23:41 +08:00
|
|
|
|
|
|
|
|
|
|
if (modal)
|
|
|
|
|
|
{
|
|
|
|
|
|
parent = UIManager.Instance.ModalsPanel;
|
|
|
|
|
|
}
|
2021-04-09 09:44:06 +08:00
|
|
|
|
else
|
2021-03-25 16:53:39 +08:00
|
|
|
|
{
|
2021-04-14 15:02:33 +08:00
|
|
|
|
var root = UIManager.Instance.Root;
|
|
|
|
|
|
for (int i = 0; i < root.transform.childCount; i++)
|
|
|
|
|
|
{
|
|
|
|
|
|
var panel1 = root.transform.GetChild(i).GetComponent<PFUIPanel>();
|
|
|
|
|
|
if (panel1 != null)
|
|
|
|
|
|
{
|
|
|
|
|
|
panel1.Close();
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if (prePanel != null)
|
2021-04-09 09:44:06 +08:00
|
|
|
|
{
|
|
|
|
|
|
prePanel.Close();
|
|
|
|
|
|
}
|
|
|
|
|
|
prePanel = panelToShow;
|
2021-03-25 16:53:39 +08:00
|
|
|
|
}
|
2021-04-14 15:02:33 +08:00
|
|
|
|
if (parent != null && parent.IsActive() == false)
|
|
|
|
|
|
{
|
|
|
|
|
|
parent.gameObject.SetActive(true);
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2021-04-09 09:44:06 +08:00
|
|
|
|
//foreach (Transform child in parent.transform)
|
|
|
|
|
|
//{
|
|
|
|
|
|
// //GameObject.Destroy(child);
|
|
|
|
|
|
// //GameObject.Destroy(child.gameObject);
|
|
|
|
|
|
// child.gameObject.SetActive(false);
|
|
|
|
|
|
//}
|
|
|
|
|
|
|
2021-03-25 16:53:39 +08:00
|
|
|
|
//var panel = UIManager.Instance.MainPanel; //UIManager.Instance.MainCanvasTransform.transform.Find("Panel");
|
|
|
|
|
|
|
|
|
|
|
|
//panel.gameObject.AddComponent<GameObject>(panelToShow.gameObject);
|
2021-04-09 09:44:06 +08:00
|
|
|
|
//panelToShow.transform.SetParent(parent.transform);
|
|
|
|
|
|
parent.AddChild(panelToShow);
|
|
|
|
|
|
//panelToShow.gameObject.SetActive(true);
|
|
|
|
|
|
panelToShow.Show();
|
2021-03-29 09:10:59 +08:00
|
|
|
|
//panelToShow.transform.position = new Vector3(0, 0, 0);
|
|
|
|
|
|
panelToShow.transform.localPosition = new Vector3(0, 0, 0);
|
|
|
|
|
|
//panelToShow.transform.localRotation = new Quaternion(0, 0, 0, 0);
|
2021-04-01 14:09:23 +08:00
|
|
|
|
|
2021-04-09 09:44:06 +08:00
|
|
|
|
//if (modal == false)
|
2021-04-01 14:09:23 +08:00
|
|
|
|
{
|
|
|
|
|
|
panelToShow.transform.GetComponent<RectTransform>().offsetMin = new Vector2(0, 0);
|
|
|
|
|
|
panelToShow.transform.GetComponent<RectTransform>().offsetMax = new Vector2(0, 0);
|
|
|
|
|
|
}
|
2021-04-14 15:02:33 +08:00
|
|
|
|
panelToShow.transform.localScale = parent.transform.localScale;
|
2021-03-25 16:53:39 +08:00
|
|
|
|
}
|
|
|
|
|
|
|
2021-04-15 10:13:01 +08:00
|
|
|
|
public static void ShowCustom(PFUIPanel panelToShow, GameObject parent = null, bool modal = false)
|
|
|
|
|
|
{
|
|
|
|
|
|
if (UIManager.Instance == null || panelToShow == null)
|
|
|
|
|
|
{
|
|
|
|
|
|
return;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if (modal)
|
|
|
|
|
|
{
|
|
|
|
|
|
parent = UIManager.Instance.ModalsPanel.gameObject;
|
|
|
|
|
|
}
|
|
|
|
|
|
else
|
|
|
|
|
|
{
|
|
|
|
|
|
if (prePanel != null)
|
|
|
|
|
|
{
|
|
|
|
|
|
prePanel.Close();
|
|
|
|
|
|
}
|
|
|
|
|
|
prePanel = panelToShow;
|
|
|
|
|
|
}
|
|
|
|
|
|
foreach (Transform child in parent.transform)
|
|
|
|
|
|
{
|
|
|
|
|
|
//GameObject.Destroy(child);
|
|
|
|
|
|
//GameObject.Destroy(child.gameObject);
|
|
|
|
|
|
child.gameObject.SetActive(false);
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
//var panel = UIManager.Instance.MainPanel; //UIManager.Instance.MainCanvasTransform.transform.Find("Panel");
|
|
|
|
|
|
|
|
|
|
|
|
//panel.gameObject.AddComponent<GameObject>(panelToShow.gameObject);
|
|
|
|
|
|
//panelToShow.transform.SetParent(parent.transform);
|
|
|
|
|
|
panelToShow.transform.parent = parent.transform;
|
|
|
|
|
|
//panelToShow.gameObject.SetActive(true);
|
|
|
|
|
|
panelToShow.Show();
|
|
|
|
|
|
//panelToShow.transform.position = new Vector3(0, 0, 0);
|
|
|
|
|
|
panelToShow.transform.localPosition = new Vector3(0, 0, 0);
|
|
|
|
|
|
//panelToShow.transform.localRotation = new Quaternion(0, 0, 0, 0);
|
|
|
|
|
|
|
|
|
|
|
|
//if (modal == false)
|
|
|
|
|
|
{
|
|
|
|
|
|
panelToShow.transform.GetComponent<RectTransform>().offsetMin = new Vector2(0, 0);
|
|
|
|
|
|
panelToShow.transform.GetComponent<RectTransform>().offsetMax = new Vector2(0, 0);
|
|
|
|
|
|
}
|
|
|
|
|
|
panelToShow.transform.localScale = parent.transform.localScale;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2021-03-25 16:53:39 +08:00
|
|
|
|
|
|
|
|
|
|
//public static void ShowHomePanel()
|
|
|
|
|
|
//{
|
|
|
|
|
|
// UIManager.Show(UIManager.Instance.PanelHome, UIManager.Instance.MainPanel);
|
|
|
|
|
|
//}
|
|
|
|
|
|
|
|
|
|
|
|
public static void ShowUserInfoPanel()
|
|
|
|
|
|
{
|
|
|
|
|
|
UIManager.Show(UIManager.Instance.UserInfoPanel, UIManager.Instance.MainPanel);
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2021-03-29 09:10:59 +08:00
|
|
|
|
public static void ShowHomePanel()
|
|
|
|
|
|
{
|
|
|
|
|
|
UIManager.Show(UIManager.Instance.HomePanel, UIManager.Instance.MainPanel);
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public static void ShowDevicePanel()
|
|
|
|
|
|
{
|
2021-04-14 15:02:33 +08:00
|
|
|
|
UIManager.Show(UIManager.Instance.DevicePanel, null, true);
|
2021-03-29 09:10:59 +08:00
|
|
|
|
}
|
2021-04-15 15:58:37 +08:00
|
|
|
|
public static void ShowSettingModal()
|
|
|
|
|
|
{
|
|
|
|
|
|
UIManager.Show(UIManager.Instance.SettingModal, null, true);
|
|
|
|
|
|
}
|
2021-04-16 17:49:11 +08:00
|
|
|
|
public static void ShowNewsModal()
|
|
|
|
|
|
{
|
|
|
|
|
|
UIManager.Show(UIManager.Instance.NewsModal, null, true);
|
|
|
|
|
|
}
|
2021-03-30 14:23:41 +08:00
|
|
|
|
public static void ShowEditUserPanel()
|
|
|
|
|
|
{
|
|
|
|
|
|
UIManager.Show(UIManager.Instance.EditUserPanel, UIManager.Instance.MainPanel);
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2021-03-25 16:53:39 +08:00
|
|
|
|
public static void ShowLoadingDialogBox()
|
|
|
|
|
|
{
|
|
|
|
|
|
}
|
2021-04-14 15:02:33 +08:00
|
|
|
|
public static void ShowMapListPanel()
|
2021-03-30 14:14:24 +08:00
|
|
|
|
{
|
|
|
|
|
|
UIManager.Show(UIManager.Instance.MapListPanel, UIManager.Instance.MainPanel);
|
|
|
|
|
|
}
|
2021-04-01 11:01:05 +08:00
|
|
|
|
public static void ShowMapDetailPanel(int id)
|
|
|
|
|
|
{
|
|
|
|
|
|
var ctrl = UIManager.Instance.MapDetailPanel;
|
|
|
|
|
|
ctrl.id = id;
|
|
|
|
|
|
UIManager.Show(UIManager.Instance.MapDetailPanel, UIManager.Instance.MainPanel);
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2021-04-14 15:02:33 +08:00
|
|
|
|
public static void ShowBigMapPanel()
|
|
|
|
|
|
{
|
|
|
|
|
|
UIManager.Instance.MainPanel.gameObject.SetActive(false);
|
|
|
|
|
|
var obj = Resources.Load("UI/Prefab/Panel/BigMapPanel");
|
|
|
|
|
|
//var root = UIManager.Instance.MainPanel.transform.parent.parent;
|
|
|
|
|
|
var bigMap = (GameObject)Instantiate(obj, UIManager.Instance.Root.transform);
|
|
|
|
|
|
|
|
|
|
|
|
//prePanel = bigMap.GetComponent<PFUIPanel>();
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2021-03-29 09:10:59 +08:00
|
|
|
|
public static void AddEvent(GameObject gameObject, EventTriggerType eventTriggerType, UnityAction<BaseEventData> call)
|
|
|
|
|
|
{
|
|
|
|
|
|
EventTrigger et = gameObject.GetComponent<EventTrigger>();
|
|
|
|
|
|
if (et == null)
|
|
|
|
|
|
{
|
|
|
|
|
|
et = gameObject.AddComponent<EventTrigger>();
|
|
|
|
|
|
}
|
|
|
|
|
|
EventTrigger.Entry pointerEvent = new EventTrigger.Entry();
|
|
|
|
|
|
pointerEvent.eventID = eventTriggerType;
|
|
|
|
|
|
pointerEvent.callback.AddListener(call);
|
|
|
|
|
|
et.triggers.Add(pointerEvent);
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2021-04-01 09:33:19 +08:00
|
|
|
|
public static void Close(MonoBehaviour obj)
|
|
|
|
|
|
{
|
|
|
|
|
|
obj.gameObject.SetActive(false);
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public static void CloseModal()
|
|
|
|
|
|
{
|
|
|
|
|
|
//foreach (var item in UIManager.Instance.ModalsPanel.transform.DetachChildren)
|
|
|
|
|
|
//{
|
|
|
|
|
|
// item.
|
|
|
|
|
|
//}
|
|
|
|
|
|
|
|
|
|
|
|
//UIManager.Instance.ModalsPanel.transform.DetachChildren();
|
|
|
|
|
|
//UIManager.Instance.ModalsPanel.transform.childCount
|
2021-04-14 15:02:33 +08:00
|
|
|
|
//for (int i = 0; i < UIManager.Instance.ModalsPanel.transform.childCount; i++)
|
2021-04-01 09:33:19 +08:00
|
|
|
|
{
|
2021-04-14 15:02:33 +08:00
|
|
|
|
var obj = UIManager.Instance.ModalsPanel.transform.GetChild(UIManager.Instance.ModalsPanel.transform.childCount - 1);
|
2021-04-01 09:33:19 +08:00
|
|
|
|
obj.gameObject.SetActive(false);
|
2021-04-14 15:02:33 +08:00
|
|
|
|
//DestroyImmediate(obj.gameObject);
|
2021-04-01 09:33:19 +08:00
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2021-04-15 15:57:29 +08:00
|
|
|
|
Alert alert = null;
|
2021-04-09 09:44:06 +08:00
|
|
|
|
public static void ShowAlert(string msg)
|
|
|
|
|
|
{
|
2021-04-14 15:02:33 +08:00
|
|
|
|
if (UIManager.Instance == null)
|
2021-04-09 09:44:06 +08:00
|
|
|
|
{
|
|
|
|
|
|
return;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if (UIManager.Instance.alert == null)
|
|
|
|
|
|
{
|
|
|
|
|
|
UIManager.Instance.alert = UIManager.Instance.GetInstance<Alert>("Alert", ref UIManager.Instance.alert);
|
|
|
|
|
|
UIManager.Instance.alert.SetText(msg);
|
|
|
|
|
|
UIManager.Show(UIManager.Instance.alert, null, true);
|
|
|
|
|
|
}
|
2021-04-14 15:02:33 +08:00
|
|
|
|
else
|
|
|
|
|
|
{
|
2021-04-09 09:44:06 +08:00
|
|
|
|
UIManager.Instance.alert.Show();
|
|
|
|
|
|
UIManager.Instance.alert.SetText(msg);
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2021-04-15 15:58:37 +08:00
|
|
|
|
public LoginRegOptions loginRegOptions { get; private set; }
|
2021-04-16 17:49:11 +08:00
|
|
|
|
private List<QUserInfo> _userInfos;
|
|
|
|
|
|
public List<QUserInfo> userInfos
|
|
|
|
|
|
{
|
|
|
|
|
|
get
|
|
|
|
|
|
{
|
|
|
|
|
|
return _userInfos;
|
|
|
|
|
|
}
|
|
|
|
|
|
set
|
|
|
|
|
|
{
|
|
|
|
|
|
_userInfos = value;
|
|
|
|
|
|
PlayerPrefs.SetString("UserInfos", JsonConvert.SerializeObject(value));
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
public Dictionary<bool, Sprite> collectDict { get; private set; }
|
2021-03-25 16:53:39 +08:00
|
|
|
|
private void OnDestroy()
|
|
|
|
|
|
{
|
|
|
|
|
|
UIManager.Instance = null;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|