using vnxbqy.UI;
|
using System.Collections.Generic;
|
using UnityEngine.UI;
|
using UnityEngine;
|
|
public class LuckyCloudAwardCell : ILBehaviour
|
{
|
ItemCell itemCell;
|
Text time;
|
Text num;
|
Text name;
|
|
protected override void Awake()
|
{
|
itemCell = proxy.GetWidgtEx<ItemCell>("itemCell");
|
time = proxy.GetWidgtEx<Text>("time");
|
num = proxy.GetWidgtEx<Text>("num");
|
name = proxy.GetWidgtEx<Text>("name");
|
}
|
|
|
//index档位字典的数组索引
|
public void Display(int index)
|
{
|
LuckyCloudBuyModel.LotteryRecInfo awards = LuckyCloudBuyModel.Instance.m_LotteryRecList[index];
|
var itemID = awards.SuperItemID;
|
var itemModel = new ItemCellModel((int)itemID, false, (ulong)awards.SuperItemCount);
|
itemCell.Init(itemModel);
|
itemCell.button.SetListener(() => {
|
ItemTipUtility.Show((int)itemID);
|
});
|
|
time.text = awards.LotteryTime;
|
num.text = awards.LotteryNum.ToString();
|
name.text = awards.PlayerName;
|
}
|
|
|
}
|