Exemplo n.º 1
0
 public void init()
 {
     this._onInit();
     foreach (var item in this.GetType().GetFields())
     {
         VOBase vo = this.GetType().GetField(item.Name).GetValue(this) as VOBase;
         if (vo != null)
         {
             vo.init();
         }
     }
 }
Exemplo n.º 2
0
        public void Show(VOBase vo)
        {
            _itemVo = (ItemVO)vo;
            if (vo == null)
            {
                Clear();
                return;
            }

            _imgIcon.sprite = Resources.Load <Sprite>(_itemVo.config.icon);
            itemIcon.SetActive(true);

            _txtCount.text = _itemVo.config.limit > 1 ? _itemVo.count.ToString():"";
        }
Exemplo n.º 3
0
        public void showTips(BaseResource config, VOBase vo)
        {
            _config = config;
            _vo     = vo;

            if (config == null && vo != null)
            {
                _config = (BaseResource)vo.GetType().GetProperty("config").GetValue(vo);
            }

            if (_config == null)
            {
                return;
            }

            _showTips();
        }