Esempio n. 1
0
        private void SetData(SelectItemMessage data)
        {
            levelName.text = data.levelName;
            switch (data.level)
            {
            case 1:
                img1.gameObject.SetActive(true);
                img2.gameObject.SetActive(false);
                img3.gameObject.SetActive(false);
                break;

            case 2:
                img1.gameObject.SetActive(false);
                img2.gameObject.SetActive(true);
                img3.gameObject.SetActive(false);
                break;

            case 3:
                img1.gameObject.SetActive(false);
                img2.gameObject.SetActive(false);
                img3.gameObject.SetActive(true);
                break;

            default:
                break;
            }
        }
Esempio n. 2
0
 protected override void UpdateView()
 {
     if (m_Data != null)
     {
         data = m_Data as SelectItemMessage;
         SetData(data);
     }
     base.UpdateView();
 }