91 lines
1.8 KiB
C#
91 lines
1.8 KiB
C#
|
|
|||
|
using UnityEngine;
|
|||
|
using UnityEngine.UI;
|
|||
|
using System.Collections;
|
|||
|
using System.Collections.Generic;
|
|||
|
using Games.GlobeDefine;
|
|||
|
using GCGame.Table;
|
|||
|
using GCGame;
|
|||
|
|
|||
|
public class MasterRelieveLogic : UIControllerBase<MasterRelieveLogic>
|
|||
|
{
|
|||
|
void OnEnable()
|
|||
|
{
|
|||
|
SetInstance(this);
|
|||
|
}
|
|||
|
|
|||
|
void OnDisable()
|
|||
|
{
|
|||
|
SetInstance(null);
|
|||
|
}
|
|||
|
|
|||
|
#region static
|
|||
|
|
|||
|
public static void ShowMasterRelieve()
|
|||
|
{
|
|||
|
Hashtable hash = new Hashtable();
|
|||
|
|
|||
|
UIManager.ShowUI(UIInfo.MasterRelieveRoot, OnMasterRelieveShow, hash);
|
|||
|
}
|
|||
|
|
|||
|
static void OnMasterRelieveShow(bool bSuccess, object param)
|
|||
|
{
|
|||
|
Hashtable hash = param as Hashtable;
|
|||
|
if (!bSuccess)
|
|||
|
{
|
|||
|
return;
|
|||
|
}
|
|||
|
if (hash == null)
|
|||
|
{
|
|||
|
return;
|
|||
|
}
|
|||
|
if (MasterRelieveLogic.Instance() != null)
|
|||
|
{
|
|||
|
MasterRelieveLogic.Instance().Show();
|
|||
|
}
|
|||
|
}
|
|||
|
|
|||
|
|
|||
|
#endregion
|
|||
|
|
|||
|
#region
|
|||
|
|
|||
|
public UIContainerBase _RelationContainer;
|
|||
|
|
|||
|
public void Show()
|
|||
|
{
|
|||
|
List<MasterRelieveItemInfo> masterInfos = new List<MasterRelieveItemInfo>();
|
|||
|
|
|||
|
MasterRelieveItemInfo item = new MasterRelieveItemInfo();
|
|||
|
item.Guid = 0;
|
|||
|
item.Level = 90;
|
|||
|
item.Name = "test1";
|
|||
|
item.Profession = 0;
|
|||
|
masterInfos.Add(item);
|
|||
|
|
|||
|
item = new MasterRelieveItemInfo();
|
|||
|
item.Guid = 1;
|
|||
|
item.Level = 100;
|
|||
|
item.Name = "test2";
|
|||
|
item.Profession = 1;
|
|||
|
masterInfos.Add(item);
|
|||
|
|
|||
|
item = new MasterRelieveItemInfo();
|
|||
|
item.Guid = 2;
|
|||
|
item.Level = 109;
|
|||
|
item.Name = "test3";
|
|||
|
item.Profession = 2;
|
|||
|
masterInfos.Add(item);
|
|||
|
|
|||
|
_RelationContainer.InitContentItem(masterInfos);
|
|||
|
}
|
|||
|
|
|||
|
public void CloseWindow()
|
|||
|
{
|
|||
|
UIManager.CloseUI(UIInfo.MasterRelieveRoot);
|
|||
|
}
|
|||
|
|
|||
|
#endregion
|
|||
|
|
|||
|
}
|