少年修仙传客户端代码仓库
client_Wu Xijin
2019-03-14 034f1835dbc7c282701426c8cb564f06fbc24b4f
3335 修改装备tips
3个文件已修改
55 ■■■■ 已修改文件
System/ItemTip/EquipTipWin.cs 13 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/ItemTip/TipGemInfoWidget.cs 36 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/ItemTip/TipLegendPropertyWidget.cs 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/ItemTip/EquipTipWin.cs
@@ -126,6 +126,8 @@
            public TipStrengthenPropertyWidget strengthenPropertyWidget;
            public TipTrainPropertyWidget trainPropertyWidget;
            public TipAuctionTipWidget auctionTipWidget;
            public Text job;
            public Text equipPlace;
            public void SetActive(bool active)
            {
@@ -187,6 +189,17 @@
                    auctionTipWidget.Display(overdueTime);
                }
                var itemConfig = ItemConfig.Get(data.itemId);
                if (JobNameConfig.Has(itemConfig.JobLimit))
                {
                    job.text = Language.Get("EquipWin_JobTitleText_1") + JobNameConfig.Get(itemConfig.JobLimit).name;
                }
                else
                {
                    job.text = "";
                }
                equipPlace.text = Language.Get("EquipWin_PartTitleText_1") + UIHelper.GetEquipPlaceName(itemConfig.EquipPlace);
            }
        }
System/ItemTip/TipGemInfoWidget.cs
@@ -29,14 +29,16 @@
        public class GemBehaviour
        {
            public Image gemIcon;
            public Image locked;
            public Text gemName;
            public Text[] propertyBehaviours;
            public Text propertyBehaviour;
            public RectTransform unLockContainer;
            public void Display(bool active, int gem)
            {
                if (active)
                {
                    locked.gameObject.SetActive(false);
                    if (gem > 0)
                    {
                        var config = ItemConfig.Get(gem);
@@ -70,44 +72,30 @@
                            properties.Add(new Int2(config.Effect5, config.EffectValueA5));
                        }
                        for (int i = 0; i < propertyBehaviours.Length; i++)
                        var lines = new string[properties.Count];
                        for (int i = 0; i < properties.Count; i++)
                        {
                            var behaviour = propertyBehaviours[i];
                            if (i < properties.Count)
                            {
                                var property = properties[i];
                                behaviour.gameObject.SetActive(true);
                                behaviour.text = string.Format("{0}+{1}", property.x, PlayerPropertyConfig.GetPropertyDescription(property.x, property.y));
                            }
                            else
                            {
                                behaviour.gameObject.SetActive(false);
                            }
                            var property = properties[i];
                            lines[i] = string.Format("{0}+{1}", property.x, PlayerPropertyConfig.GetPropertyDescription(property.x, property.y));
                        }
                        propertyBehaviour.text = string.Join("\r\n", lines);
                    }
                    else
                    {
                        gemIcon.gameObject.SetActive(false);
                        gemName.text = "未镶嵌";
                        for (int i = 0; i < propertyBehaviours.Length; i++)
                        {
                            var behaviour = propertyBehaviours[i];
                            behaviour.gameObject.SetActive(false);
                        }
                        propertyBehaviour.gameObject.SetActive(false);
                    }
                    unLockContainer.gameObject.SetActive(false);
                }
                else
                {
                    locked.gameObject.SetActive(true);
                    gemIcon.gameObject.SetActive(false);
                    gemName.text = "未镶嵌";
                    for (int i = 0; i < propertyBehaviours.Length; i++)
                    {
                        var behaviour = propertyBehaviours[i];
                        behaviour.gameObject.SetActive(false);
                    }
                    propertyBehaviour.gameObject.SetActive(false);
                    unLockContainer.gameObject.SetActive(true);
                }
            }
System/ItemTip/TipLegendPropertyWidget.cs
@@ -17,19 +17,19 @@
        {
            var count = data.properties.Count;
            var lines = new string[count];
            for (int i = 0; i < count; i++)
            {
                var property = data.properties[i];
                var config = PlayerPropertyConfig.Get(property.x);
                var value = PlayerPropertyConfig.GetPropertyDescription(property.x, property.y);
                var quality = LegendPropertyConfig.Get(property.x).quality;
                if (data.isPreview)
                {
                    lines[i] = string.Format("[推荐]{0}+{1}", config.Name, value);
                    lines[i] = UIHelper.AppendColor(quality, string.Format("[推荐]{0}+{1}", config.Name, value));
                }
                else
                {
                    lines[i] = string.Format("{0}+{1}", config.Name, value);
                    lines[i] = UIHelper.AppendColor(quality, string.Format("{0}+{1}", config.Name, value));
                }
            }