/// <summary>
    /// 设置回购数据
    /// </summary>
    /// <param name="sellBackVO"></param>
    /// <param name="isList">是否列表模式</param>
    public void SetData(ShopSellBackVO sellBackVO, bool isList)
    {
        Init();
        m_SellBackVO    = sellBackVO;
        m_Quality.color = ColorUtil.GetColorByItemQuality(sellBackVO.ItemConfig.Quality);
        if (isList)
        {
            UIUtil.SetIconImage(m_Icon, TableUtil.GetItemIconBundle((uint)m_SellBackVO.Tid), TableUtil.GetItemIconImage((uint)m_SellBackVO.Tid));
            UIUtil.SetIconImage(m_Icon2, TableUtil.GetItemIconBundle((uint)m_SellBackVO.Tid), TableUtil.GetItemIconImage((uint)m_SellBackVO.Tid));
        }
        else
        {
            UIUtil.SetIconImage(m_Icon, TableUtil.GetItemIconBundle((uint)m_SellBackVO.Tid), TableUtil.GetItemSquareIconImage((uint)m_SellBackVO.Tid));
            UIUtil.SetIconImage(m_Icon2, TableUtil.GetItemIconBundle((uint)m_SellBackVO.Tid), TableUtil.GetItemSquareIconImage((uint)m_SellBackVO.Tid));
        }
        m_Num.text = sellBackVO.Num.ToString();
        UIUtil.SetIconImage(m_MoneyIcon, TableUtil.GetItemIconBundle((uint)sellBackVO.ItemConfig.SellCurrency), TableUtil.GetItemIconImage((uint)sellBackVO.ItemConfig.SellCurrency));
        m_Price.text = sellBackVO.ItemConfig.BuybackPrice.ToString();
        m_Name.text  = TableUtil.GetItemName((uint)m_SellBackVO.Tid);
        m_Level.text = TableUtil.ShowLevel(1);


        if (MoneyeEnough())
        {
            m_Price.color = new Color(30f / 255f, 170f / 255f, 33f / 255f, 1);
        }
        else
        {
            m_Price.color = Color.red;
        }
    }
    /// <summary>
    /// 根据类型初始化面板内容
    /// </summary>
    private void SetContent()
    {
        m_Prime.gameObject.SetActive(false);
        m_BlueprintNameLabel.text   = TableUtil.GetItemName(m_CurrentProduce.Id);
        m_BlueprintQuality.color    = ColorUtil.GetColorByItemQuality(TableUtil.GetItemQuality(m_CurrentItem.Id));
        m_BlueprintNumberLabel.text = m_CurrentProduce.ProductNum.ToString();
        string iconName = "";

        if (m_Style == UIViewListLayout.Row)
        {
            iconName = TableUtil.GetItemIconImage(m_CurrentItem.Id);
        }
        else
        {
            iconName = TableUtil.GetItemSquareIconImage(m_CurrentItem.Id);
        }

        UIUtil.SetIconImage(m_IconImage, TableUtil.GetItemIconBundle(m_CurrentItem.Id), iconName);
        m_OverlyingIcon.sprite = m_IconImage.sprite;
        switch (m_ProduceType)
        {
        case ProduceType.HeavyWeapon:
        case ProduceType.LightWeapon:
            WeaponL2 weaponL2 = 0;
            ItemTypeUtil.SetSubType(ref weaponL2, ItemTypeUtil.GetItemType(m_CurrentItem.Type));
            m_Prime.text = TableUtil.GetLanguageString(weaponL2);
            m_Prime.gameObject.SetActive(true);
            break;
        }
    }
 public void SetData(ItemBase item, bool isSelect, bool isList = false)
 {
     Init();
     m_Quality.color = ColorUtil.GetColorByItemQuality(item.ItemConfig.Quality);
     if (isList)
     {
         UIUtil.SetIconImage(m_Icon, TableUtil.GetItemIconBundle(item.TID), TableUtil.GetItemIconImage(item.TID));
         UIUtil.SetIconImage(m_Icon2, TableUtil.GetItemIconBundle(item.TID), TableUtil.GetItemIconImage(item.TID));
     }
     else
     {
         UIUtil.SetIconImage(m_Icon, TableUtil.GetItemIconBundle(item.TID), TableUtil.GetItemSquareIconImage(item.TID));
         UIUtil.SetIconImage(m_Icon2, TableUtil.GetItemIconBundle(item.TID), TableUtil.GetItemSquareIconImage(item.TID));
     }
     m_Count.text = item.Count.ToString();
     m_Used.gameObject.SetActive(item.Replicas != null && item.Replicas.Count > 0);
     m_Price.text = item.ItemConfig.MoneyPrice.ToString();
     if (isSelect)
     {
         m_Price.color = new Color(41f / 255f, 41f / 255f, 41f / 255f, 1);
     }
     else
     {
         m_Price.color = Color.white;
     }
     m_Name.text  = TableUtil.GetItemName(item.TID);
     m_Level.text = TableUtil.ShowLevel(1);
     UIUtil.SetIconImage(m_MoneyIcon, TableUtil.GetItemIconBundle((uint)item.ItemConfig.SellCurrency), TableUtil.GetItemIconImage((uint)item.ItemConfig.SellCurrency));
 }
    /// <summary>
    /// 等级奖励
    /// </summary>
    private void LevelRewards()
    {
        int index = 0;

        if (m_RewarList.Count == 0)
        {
            m_RewardContainer.gameObject.SetActive(false);
            return;
        }
        m_RewardContainer.gameObject.SetActive(true);
        for (; index < m_RewarList.Count; index++)
        {
            RewardDateVO mailReward = m_RewarList[index];
            Transform    node       = index < m_RewardContainer.childCount ? m_RewardContainer.GetChild(index) : Object.Instantiate(m_RewardContainer.GetChild(0), m_RewardContainer);
            Image        icon       = FindComponent <Image>(node, "Icon");
            Image        quality    = FindComponent <Image>(node, "Quality");
            TMP_Text     num        = FindComponent <TMP_Text>(node, "label_Num");
            num.text      = mailReward.Num.ToString();
            quality.color = ColorUtil.GetColorByItemQuality(mailReward.Quality);
            string iconName = TableUtil.GetItemSquareIconImage(mailReward.Id);
            UIUtil.SetIconImage(icon, TableUtil.GetItemIconBundle(mailReward.Id), iconName);
            node.gameObject.SetActive(true);
        }
        for (; index < m_RewardContainer.childCount; index++)
        {
            m_RewardContainer.GetChild(index).gameObject.SetActive(false);
        }
    }
    public void SetData(ItemWeaponVO Vo)
    {
        Initialize();
        m_Empty.gameObject.SetActive(Vo.TID == 0);
        m_Content.gameObject.SetActive(Vo.TID != 0);
        if (Vo.TID == 0)
        {
            return;
        }
        UIUtil.SetIconImage(m_IconImage, TableUtil.GetItemIconBundle(Vo.TID), TableUtil.GetItemIconImage(Vo.TID));
        m_OverlyingIcon.sprite = m_IconImage.sprite;
        m_NameLabel.text       = TableUtil.GetItemName((int)Vo.TID);
        m_Quality.color        = ColorUtil.GetColorByItemQuality(Vo.ItemConfig.Quality);
        m_Used.gameObject.SetActive(Vo.Replicas != null && Vo.Replicas.Count > 0);
        int index = 0;

        char[] charArray = Vo.Lv.ToString().PadLeft(3, '0').ToCharArray();
        for (int i = 0; i < charArray.Length; i++)
        {
            char cc = charArray[i];
            if (cc != '0')
            {
                index = i;
                break;
            }
        }
        string sstr = Vo.Lv.ToString().PadLeft(3, '0');

        if (index != 0)
        {
            sstr = sstr.Insert(index, "</color>");
            sstr = sstr.Insert(0, "<color=#808080>");
        }
        m_LvLabel.text   = sstr;
        m_TypeLabel.text = TableUtil.GetLanguageString(Vo.WeaponType2);
        int m_ModCount = 0;

        if (Vo.Items != null)
        {
            foreach (ItemContainer item in Vo.Items.Values)
            {
                if (item.Items != null)
                {
                    m_ModCount += item.Items.Count;
                }
            }
        }
        SetMod(m_ModCount);
    }
Exemple #6
0
 public void SetData(ItemBase Vo)
 {
     Initialize();
     m_Empty.gameObject.SetActive(Vo.TID == 0);
     m_Content.gameObject.SetActive(Vo.TID != 0);
     if (Vo.TID == 0)
     {
         return;
     }
     UIUtil.SetIconImage(m_IconImage, TableUtil.GetItemIconBundle(Vo.TID), TableUtil.GetItemIconImage(Vo.TID));
     m_OverlyingIcon.sprite = m_IconImage.sprite;
     m_NameLabel.text       = TableUtil.GetItemName((int)Vo.TID);
     m_Quality.color        = ColorUtil.GetColorByItemQuality(Vo.ItemConfig.Quality);
     m_NumLabel.text        = Vo.Count.ToString();
     m_TypeLabel.text       = TableUtil.GetLanguageString(Vo.MainType);
 }
    /// <summary>
    ///
    /// </summary>
    /// <param name="view"></param>
    /// <param name="data"></param>
    private void LayoutMailTip(GameObject view, MailDataVO data)
    {
        int             index           = 0;
        Transform       m_TipsTransform = FindComponent <Transform>(view.transform, "TipsScrollView/ALL");
        TextMeshProUGUI m_Title         = FindComponent <TextMeshProUGUI>(view.transform, "TipsScrollView/ALL/Content/NameType/Label_Name");
        TextMeshProUGUI m_Sender        = FindComponent <TextMeshProUGUI>(view.transform, "TipsScrollView/ALL/Content/NameType/Type/Label_Type");
        TextMeshProUGUI m_Describe      = FindComponent <TextMeshProUGUI>(view.transform, "TipsScrollView/ALL/Content/Describe/Label_Describe");

        Transform itemRootTf = FindComponent <Transform>(view.transform, "TipsScrollView/ALL/Content/Materials");

        m_Title.text    = data.Title;
        m_Sender.text   = data.Sender;
        m_Describe.text = data.Content;
        m_Describe.text = m_Describe.text.Replace("\\n", "\n");
        if (data.Items == null)
        {
            return;
        }
        for (; index < data.Items.Count; index++)
        {
            RewardDateVO mailReward = data.Items[index];
            Transform    node       = index < itemRootTf.childCount ? itemRootTf.GetChild(index) : Object.Instantiate(itemRootTf.GetChild(0), itemRootTf);
            Image        icon       = FindComponent <Image>(node, "Content/Icon/Icon");
            Image        quality    = FindComponent <Image>(node, "Content/Icon/Quality");
            TMP_Text     name       = FindComponent <TMP_Text>(node, "Content/Label_Name");
            TMP_Text     num        = FindComponent <TMP_Text>(node, "Content/Label_Num");
            name.text     = TableUtil.GetItemName((int)mailReward.Id);
            num.text      = mailReward.Num.ToString();
            quality.color = ColorUtil.GetColorByItemQuality(mailReward.Quality);
            string iconName = TableUtil.GetItemSquareIconImage(mailReward.Id);
            UIUtil.SetIconImage(icon, TableUtil.GetItemIconBundle(mailReward.Id), iconName);
            if (data.Got == 1)
            {
                icon.color = Color.gray;
            }
            else
            {
                icon.color = Color.white;
            }
            node.gameObject.SetActive(true);
        }
        for (; index < itemRootTf.childCount; index++)
        {
            itemRootTf.GetChild(index).gameObject.SetActive(false);
        }
    }
Exemple #8
0
    /// <summary>
    /// 添加条目
    /// </summary>
    /// <param name="itemGetting">条目数据</param>
    private void OnGettingItem(ItemChangeInfo itemGetting)
    {
        if (itemGetting.CountChangeDelta > 0 && itemGetting.TID > 0)
        {
            if (itemGetting.Category != 0 && itemGetting.Category != Category.Package)
            {
                ItemData data = new ItemData();
                data.Name       = TableUtil.GetItemName(itemGetting.TID);
                data.Quality    = TableUtil.GetItemQuality(itemGetting.TID);
                data.Count      = itemGetting.CountChangeDelta;
                data.IconBundle = TableUtil.GetItemIconBundle(itemGetting.TID);
                data.IconName   = TableUtil.GetItemSquareIconImage(itemGetting.TID);

                m_WaitingQueue.Add(data);
            }
        }
    }
 /// <summary>
 /// 设置船内容显示
 /// </summary>
 /// <param name="ship"></param>
 public void SetData(IShip ship, bool isList)
 {
     Initialize();
     m_Ship = ship;
     if (isList)
     {
         UIUtil.SetIconImage(m_IconImage, TableUtil.GetItemIconBundle(ship.GetTID()), TableUtil.GetItemIconImage(ship.GetTID()));
     }
     else
     {
         UIUtil.SetIconImage(m_IconImage, TableUtil.GetItemIconBundle(ship.GetTID()), TableUtil.GetItemSquareIconImage(ship.GetTID()));
     }
     m_OverlyingIcon.sprite = m_IconImage.sprite;
     m_NameLabel.text       = TableUtil.GetItemName((int)ship.GetTID());
     m_LvLabel.text         = TableUtil.ShowLevel(ship.GetLv());
     m_Appoint.gameObject.SetActive(ship.GetUID() == m_ShipProxy.GetAppointWarShip().GetUID());
     m_New.gameObject.SetActive(!m_ShipProxy.MarkNew(ship));
 }
Exemple #10
0
    /// <summary>
    /// 设置日志内容显示
    /// </summary>
    private void SetContent(LogDataVO dataVO)
    {
        UIUtil.SetIconImage(m_Icon, TableUtil.GetItemIconBundle(dataVO.Tid), TableUtil.GetItemIconImage(dataVO.Tid));
        UIUtil.SetIconImage(m_OverlyingIcon, TableUtil.GetItemIconBundle(dataVO.Tid), TableUtil.GetItemIconImage(dataVO.Tid));
        Color  m_QualityColor = ColorUtil.GetColorByItemQuality(TableUtil.GetItemQuality(dataVO.Tid));
        string m_Name         = TableUtil.GetItemName(dataVO.Tid);
        string m_ColorText    = ColorUtil.AddColor(m_Name, m_QualityColor);
        string m_ShowText     = "";

        if (dataVO.Num > 1)
        {
            m_ShowText = string.Format(TableUtil.GetLanguageString("log_text_1011"), m_ColorText, dataVO.Num);
        }
        else
        {
            m_ShowText = string.Format(TableUtil.GetLanguageString("log_text_1010"), m_ColorText);
        }
        m_Describe.text = string.Format(m_ShowText);
    }
    private void ShowModMessageTips(WarshipModPanelElement cell)
    {
        m_ModTips.transform.localPosition = cell.transform.localPosition;
        m_ModTips.gameObject.SetActive(true);

        TransformUtil.FindUIObject <Transform>(m_ModTips.transform, "Content").gameObject.SetActive(cell.HasData());
        TransformUtil.FindUIObject <Transform>(m_ModTips.transform, "Empty").gameObject.SetActive(!cell.HasData());

        if (cell.HasData())
        {
            UIUtil.SetIconImage(
                TransformUtil.FindUIObject <Image>(m_ModTips.transform, "Content/Image_Icon"),
                TableUtil.GetItemIconBundle(cell.GetModTid()),
                TableUtil.GetItemIconImage(cell.GetModTid()),
                autoSetNativeSize: true);

            TransformUtil.FindUIObject <Image>(m_ModTips.transform, "Content/Image_Quality").color = ColorUtil.GetColorByItemQuality(m_CfgEternityProxy.GetItemByKey(cell.GetModTid()).Quality);

            //数字不足3位,补0 ,并将补充的颜色置灰
            int    lv        = cell.GetLv();
            int    index     = 0;
            char[] charArray = lv.ToString().PadLeft(3, '0').ToCharArray();
            for (int i = 0; i < charArray.Length; i++)
            {
                char cc = charArray[i];
                if (cc != '0')
                {
                    index = i;
                    break;
                }
            }
            string sstr = lv.ToString().PadLeft(3, '0');
            if (index != 0)
            {
                sstr = sstr.Insert(index, "</color>");
                sstr = sstr.Insert(0, "<color=#808080>");
            }
            TransformUtil.FindUIObject <TMP_Text>(m_ModTips.transform, "Content/Label_Lv").text = sstr;

            TransformUtil.FindUIObject <TMP_Text>(m_ModTips.transform, "Content/Label_Name").text = TableUtil.GetItemName(cell.GetModTid());
        }
    }
Exemple #12
0
    /// <summary>
    /// 设置船具体属性数据
    /// </summary>
    private void SetShipData()
    {
        InitShipPanel();

        m_ShipPanelEmptyRoot.SetActive(false);
        m_ShipPanelContentRoot.SetActive(true);

        UIUtil.SetIconImage(m_ShipPanelIcon, TableUtil.GetItemIconBundle(m_CurrentShip.GetTID()), TableUtil.GetItemIconImage(m_CurrentShip.GetTID()));
        m_ShipPanelNameText.text      = TableUtil.GetItemName((int)m_CurrentShip.GetTID());
        m_ShipPanelQualityImage.color = ColorUtil.ShipColor.GetColorByPrime(m_CurrentShip.GetConfig().IsPrime > 0);
        m_ShipPanelLvText.text        = "Lv." + PadLeft(m_CurrentShip.GetLv().ToString());

        uint modCount = m_CurrentShip.GetGeneralModContainer().GetCurrentSizeMax() + m_CurrentShip.GetExclusivelyModContainer().GetCurrentSizeMax();

        for (int i = 0; i < m_ShipMods.Length; i++)
        {
            m_ShipMods[i].gameObject.SetActive(i < modCount);
            m_ShipMods[i].transform.GetChild(0).GetComponent <Image>().enabled = false;
        }

        IMod[] mods = m_CurrentShip.GetGeneralModContainer().GetMods();
        if (mods != null && mods.Length > 0)
        {
            for (int i = 0; i < mods.Length; i++)
            {
                m_ShipMods[mods[i].GetPos()].transform.GetChild(0).GetComponent <Image>().enabled = true;
                m_ShipMods[mods[i].GetPos()].transform.GetChild(0).GetComponent <Image>().color   = ColorUtil.GetColorByItemQuality(mods[i].GetBaseConfig().Quality);
            }
        }
        mods = m_CurrentShip.GetExclusivelyModContainer().GetMods();
        uint GeneralModCount = m_CurrentShip.GetGeneralModContainer().GetCurrentSizeMax();

        if (mods != null && mods.Length > 0)
        {
            for (int i = 0; i < mods.Length; i++)
            {
                m_ShipMods[mods[i].GetPos() + GeneralModCount].transform.GetChild(0).GetComponent <Image>().enabled = true;
                m_ShipMods[mods[i].GetPos() + GeneralModCount].transform.GetChild(0).GetComponent <Image>().color   = ColorUtil.GetColorByItemQuality(mods[i].GetBaseConfig().Quality);
            }
        }
    }
Exemple #13
0
 /// <summary>
 /// 设置单个装备数据
 /// </summary>
 /// <param name="data"></param>
 /// <param name="cell"></param>
 private void SetEquipmentData(IEquipment data, Transform cell)
 {
     TransformUtil.FindUIObject <Transform>(cell, "Content").gameObject.SetActive(data != null);
     TransformUtil.FindUIObject <Transform>(cell, "Empty").gameObject.SetActive(data == null);
     if (data != null)
     {
         //icon
         UIUtil.SetIconImage(TransformUtil.FindUIObject <Image>(cell, "Content/Image_Icon"), TableUtil.GetItemIconBundle(data.GetTID()), TableUtil.GetItemIconImage(data.GetTID()));
         //name
         TransformUtil.FindUIObject <TMP_Text>(cell, "Content/Label_Name").text = TableUtil.GetItemName((int)data.GetTID());
         //quality
         TransformUtil.FindUIObject <Image>(cell, "Content/Image_Quality").color = ColorUtil.GetColorByItemQuality(data.GetBaseConfig().Quality);
         //lv
         TransformUtil.FindUIObject <TMP_Text>(cell, "Content/Label_Lv").text = "Lv." + PadLeft(data.GetLv().ToString());
     }
 }
Exemple #14
0
    public override void OnShow(object msg)
    {
        base.OnShow(msg);
        if (msg != null)
        {
            m_ShopParameter = (OpenShopParameter)msg;
        }
        m_ItemConfig = m_CfgEternityProxy.GetItemByKey(m_ShopParameter.Tid);
        m_Bounds     = m_ShopParameter.Bounds;
        if (m_ShopParameter.MoneyType == 1)
        {
            m_Money = (int)CurrencyUtil.GetGameCurrencyCount();
        }
        else
        {
            m_Money = (int)CurrencyUtil.GetRechargeCurrencyCount();
        }
        if (m_ShopParameter.OperateType == 1)
        {
            m_Max = m_ShopParameter.LimitCount;
        }
        else
        {
            GetGoodMax();
            if (m_Max == 0)
            {
                m_Min = 0;
            }
        }
        m_GoodName.text  = TableUtil.GetItemName(m_ShopParameter.Tid);
        m_GoodName.color = ColorUtil.GetColorByItemQuality(m_ItemConfig.Quality);
        UIUtil.SetIconImage(m_MoneyIcon, TableUtil.GetItemIconBundle((KNumMoneyType)m_ShopParameter.MoneyType), TableUtil.GetItemIconImage((KNumMoneyType)m_ShopParameter.MoneyType));
        m_InputBox.onValueChanged.RemoveAllListeners();
        m_CurrentNum      = m_Bounds;
        m_InputBox.text   = m_Bounds.ToString();
        m_TotalPrice.text = Mathf.CeilToInt(m_CurrentNum * (m_ShopParameter.Price / m_ShopParameter.Bounds)).ToString();

        m_InputBox.onValueChanged.AddListener((str) =>
        {
            if (str.Length > 0)
            {
                m_CurrentNum = int.Parse(str);
                if (m_CurrentNum < m_Min)
                {
                    m_CurrentNum = m_Min;
                }
                else if (m_CurrentNum > m_Max)
                {
                    m_CurrentNum = m_Max;
                }
                m_InputBox.text = m_CurrentNum.ToString();
                m_BtnLeft.GetComponent <Button>().interactable  = m_CurrentNum > m_Bounds;
                m_BtnRight.GetComponent <Button>().interactable = m_CurrentNum < m_Max;
                SetHotKeyEnabled("left", m_CurrentNum > m_Bounds);
                SetHotKeyEnabled("Right", m_CurrentNum < m_Max);
                int m_Price       = Mathf.CeilToInt(m_CurrentNum * (m_ShopParameter.Price / m_ShopParameter.Bounds));
                m_TotalPrice.text = m_Price.ToString();
                if (m_ShopParameter.OperateType != 1)
                {
                    SetHotKeyEnabled("confirm", m_Money >= m_Price && m_CurrentNum > 0);
                }
                else
                {
                    SetHotKeyEnabled("confirm", true);
                }
            }
            else
            {
                m_CurrentNum      = 0;
                int m_Price       = 0;
                m_TotalPrice.text = m_Price.ToString();
                SetHotKeyEnabled("confirm", false);
            }
        });
        UIEventListener.UIEventListener.AttachListener(m_BtnLeft).onDown  = OnLeftDonw;
        UIEventListener.UIEventListener.AttachListener(m_BtnLeft).onUp    = OnUp;
        UIEventListener.UIEventListener.AttachListener(m_BtnRight).onDown = OnRightDown;
        UIEventListener.UIEventListener.AttachListener(m_BtnRight).onUp   = OnUp;
    }
Exemple #15
0
    /// <summary>
    ///  设置商品数据
    /// </summary>
    /// <param name="shopWindowVO"></param>
    /// <param name="isSelect"></param>
    /// <param name="isList"></param>
    public void SetData(ShopWindowVO shopWindowVO, bool isSelect, bool isList = false)
    {
        Init();
        Item m_Item = shopWindowVO.ShopItemConfig.Value.ItemGood.Value;

        m_ShopItemData  = shopWindowVO.ShopItemConfig.Value;
        m_Quality.color = ColorUtil.GetColorByItemQuality(m_Item.Quality);
        if (isList)
        {
            UIUtil.SetIconImage(m_Icon, TableUtil.GetItemIconBundle(m_Item.Id), TableUtil.GetItemIconImage(m_Item.Id));
            UIUtil.SetIconImage(m_Icon2, TableUtil.GetItemIconBundle(m_Item.Id), TableUtil.GetItemIconImage(m_Item.Id));
        }
        else
        {
            UIUtil.SetIconImage(m_Icon, TableUtil.GetItemIconBundle(m_Item.Id), TableUtil.GetItemSquareIconImage(m_Item.Id));
            UIUtil.SetIconImage(m_Icon2, TableUtil.GetItemIconBundle(m_Item.Id), TableUtil.GetItemSquareIconImage(m_Item.Id));
        }
        m_Name.text   = TableUtil.GetItemName(m_Item.Id);
        m_Level.text  = TableUtil.ShowLevel(1);
        m_Bounds.text = m_ShopItemData.Bounds.ToString();
        if (shopWindowVO.LimitCount == -1)
        {
            m_Available.gameObject.SetActive(false);
        }
        else
        {
            m_Available.gameObject.SetActive(true);
            m_Available.text = string.Format(TableUtil.GetLanguageString("shop_text_1012"), shopWindowVO.LimitCount);
        }
        if (shopWindowVO.LimitCount < m_ShopItemData.Bounds)
        {
            m_Available.color = Color.red;
        }
        else
        {
            m_Available.color = isSelect ? new Color(41f / 255f, 41f / 255f, 41f / 255f, 1) : Color.white;
        }

        UIUtil.SetIconImage(m_MoneyIcon, TableUtil.GetItemIconBundle((KNumMoneyType)m_ShopItemData.MoneyType), TableUtil.GetItemIconImage((KNumMoneyType)m_ShopItemData.MoneyType));
        if (m_ShopItemData.DisCount == 1)
        {
            m_Discount.gameObject.SetActive(false);
            m_GoodPrice = m_ShopItemData.BuyCost;
        }
        else
        {
            m_Discount.gameObject.SetActive(true);
            m_Discount.text = m_ShopItemData.BuyCost.ToString();
            m_GoodPrice     = Mathf.CeilToInt(m_ShopItemData.BuyCost * m_ShopItemData.DisCount);
        }
        m_Price.text = m_GoodPrice.ToString();

        if (MoneyeEnough())
        {
            m_Price.color = new Color(30f / 255f, 170f / 255f, 33f / 255f, 1);
        }
        else
        {
            m_Price.color = Color.red;
        }
        if (shopWindowVO.ServerLeftNum == -1)
        {
            m_Stock.text = TableUtil.GetLanguageString("shop_text_1010");
        }
        else if (shopWindowVO.ServerLeftNum == 0)
        {
            m_Stock.text = TableUtil.GetLanguageString("shop_text_1013");
        }
        else
        {
            m_Stock.text = string.Format(TableUtil.GetLanguageString("shop_text_1011"), shopWindowVO.ServerLeftNum);
        }
        m_Stock.color = isSelect ? new Color(41f / 255f, 41f / 255f, 41f / 255f, 1) : Color.white;
        m_Black.gameObject.SetActive(shopWindowVO.IsOpen == 0);
    }