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