using System.Collections.Generic;
|
using UnityEngine;
|
|
public class HeroFatesFastPutPreviewCell : MonoBehaviour
|
{
|
[SerializeField] List<HeroFatesUpgradeHeadCell> headCells;
|
HeroFatesManager manager { get { return HeroFatesManager.Instance; } }
|
|
public void Display(int rowIndex, List<HeroInfo> list)
|
{
|
if (list.IsNullOrEmpty())
|
{
|
return;
|
}
|
|
for (int i = 0; i < headCells.Count; i++)
|
{
|
int index = rowIndex * manager.rowCountMax + i;
|
if (index < list.Count)
|
{
|
headCells[i].SetActive(true);
|
headCells[i].Display(list[index]);
|
}
|
else
|
{
|
headCells[i].SetActive(false);
|
}
|
}
|
}
|
|
}
|