少年修仙传客户端代码仓库
lcy
2024-12-16 a39c35fc6449430cd02bccb681c4a0a880e46cd9
提交 | 用户 | age
eb222a 1 //--------------------------------------------------------
CX 2 //    [Author]:           第二世界
3 //    [  Date ]:           Thursday, July 18, 2019
4 //--------------------------------------------------------
5 using UnityEngine;
6 using System.Collections;
7 using UnityEngine.UI;
8
4465b6 9 namespace vnxbqy.UI
eb222a 10 {
CX 11
12     public class EquipStarSuccessActiveItemBehaviour : MonoBehaviour
13     {
14         [SerializeField] Text m_Title;
6d4c04 15         [SerializeField] RectTransform m_ContainerContent;
eb222a 16         [SerializeField] Text m_Content;
CX 17
04d2f8 18         public string GetContent()
H 19         {
20             return m_Title.text;
21         }
22
c95dd3 23
eb222a 24         public void DisplaySuitEffect(int star, EquipSuitType suitType, Int2[] properties)
CX 25         {
f23c81 26             m_ContainerContent.SetActive(true);
eb222a 27             m_Title.text = Language.Get("StarUpgradeSuccessTip1", EquipStarEffectTipModel.GetStarNumberCHS(star));
CX 28             var lines = new string[properties.Length];
29             for (var i = 0; i < properties.Length; i++)
30             {
31                 var property = properties[i];
32                 switch (suitType)
33                 {
34                     case EquipSuitType.TwoSuit:
dee74a 35                         lines[i] = Language.Get("EquipStar14", EquipStarEffectTipModel.GetStarNumberCHS(2),
eb222a 36                             PlayerPropertyConfig.GetFullDescription(property.x, property.y));
CX 37                         break;
38                     case EquipSuitType.FiveSuit:
dee74a 39                         lines[i] = Language.Get("EquipStar14", EquipStarEffectTipModel.GetStarNumberCHS(5),
eb222a 40                             PlayerPropertyConfig.GetFullDescription(property.x, property.y));
CX 41                         break;
42                     case EquipSuitType.EightSuit:
dee74a 43                         lines[i] = Language.Get("EquipStar14", EquipStarEffectTipModel.GetStarNumberCHS(8),
eb222a 44                             PlayerPropertyConfig.GetFullDescription(property.x, property.y));
CX 45                         break;
46                 }
47             }
48
49             m_Content.text = string.Join("\n", lines);
50         }
51
52         public void DisplaySuitEffect(int star, string skillDescription)
53         {
f23c81 54             m_ContainerContent.SetActive(true);
eb222a 55             m_Title.text = Language.Get("StarUpgradeSuccessTip1", EquipStarEffectTipModel.GetStarNumberCHS(star));
dee74a 56             m_Content.text = Language.Get("EquipStar14", EquipStarEffectTipModel.GetStarNumberCHS(8), skillDescription);
eb222a 57         }
CX 58
59         public void DisplayStarProperty(int star, Int2 property)
60         {
f23c81 61             m_ContainerContent.SetActive(true);
eb222a 62             m_Title.text = Language.Get("StarUpgradeSuccessTip2", EquipStarEffectTipModel.GetStarNumberCHS(star));
CX 63             m_Content.text = PlayerPropertyConfig.GetFullDescription(property.x, property.y);
64         }
65
66         public void DisplayGemHole(int star)
67         {
68             switch (star)
69             {
70                 case 2:
71                     m_Title.text = Language.Get("StarUpgradeSuccessTip3", EquipStarEffectTipModel.GetStarNumberCHS(2));
72                     break;
73                 case 5:
74                     m_Title.text = Language.Get("StarUpgradeSuccessTip3", EquipStarEffectTipModel.GetStarNumberCHS(3));
75                     break;
76             }
77
f23c81 78             m_ContainerContent.SetActive(false);
eb222a 79         }
CX 80
81         public void DisplayTrainLevelLimit(int star, int trainLevel)
82         {
83             m_Title.text = Language.Get("StarUpgradeSuccessTip5", trainLevel);
f23c81 84             m_ContainerContent.SetActive(false);
eb222a 85         }
CX 86
87         public void DisplayStrengthLevelLimit(int star, int strengthLevel)
88         {
89             m_Title.text = Language.Get("StarUpgradeSuccessTip4", strengthLevel);
f23c81 90             m_ContainerContent.SetActive(false);
eb222a 91         }
CX 92
93     }
94
95 }
96
97
98