52 lines
1.3 KiB
C#
52 lines
1.3 KiB
C#
|
|
using UnityEngine;
|
|
using UnityEngine.UI;
|
|
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using GCGame.Table;
|
|
using Games.Mission;
|
|
using Games.Events;
|
|
using Games.Item;
|
|
|
|
public class EquipGemSuitItem : UIItemSelect
|
|
{
|
|
public Text _Name;
|
|
public UIContainerSelect _GemContainer;
|
|
public Text _MaxCombat;
|
|
|
|
private Tab_GemSuit _Gemsuit;
|
|
|
|
public override void Show(Hashtable hash)
|
|
{
|
|
base.Show();
|
|
|
|
_Gemsuit = (Tab_GemSuit)hash["InitObj"];
|
|
GameItem equipItem = null;
|
|
if (hash.ContainsKey("EquipItem"))
|
|
{
|
|
equipItem = (GameItem)hash["EquipItem"];
|
|
}
|
|
ShowGem(_Gemsuit, equipItem);
|
|
}
|
|
|
|
public void ShowGem(Tab_GemSuit gemData, GameItem equipItem)
|
|
{
|
|
_Name.text = gemData.Name;
|
|
_MaxCombat.text = gemData.CombatValue.ToString();
|
|
|
|
List<int> gemDatas = new List<int>();
|
|
//for (int i = 0; i < gemData.getGemIDCount(); ++i)
|
|
//{
|
|
// int gemID = gemData.GetGemIDbyIndex(i);
|
|
// if (gemID > 0)
|
|
// {
|
|
// gemDatas.Add(gemID);
|
|
// }
|
|
//}
|
|
Hashtable hash = new Hashtable();
|
|
hash.Add("EquipItem", equipItem);
|
|
_GemContainer.InitSelectContent(gemDatas, null, null, null, hash);
|
|
}
|
|
|
|
}
|