少年修仙传客户端代码仓库
hch
2025-07-02 600733c8f592cb9e65f2b7a3e110ac1d686e6bfe
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
using vnxbqy.UI;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
 
public class EvolvePropertyCell : ILBehaviour
{
    Text pro;
    Image newimg;
 
 
    protected override void Awake() 
    {
        pro = proxy.GetWidgtEx<Text>("Text");
        newimg = proxy.GetWidgtEx<Image>("image");
    }
 
    public void Display(int finalEquipID, int equipID, int index)
    {
        var equipInfo = EquipShenAttrConfig.Get(finalEquipID);
        int propertyId = 0;
        int value = 0;
        int quality = EquipEvolveModel.Instance.GetRedEquipQuality(equipID);
        string preText = "";
 
        newimg.SetActiveIL(false);
        Color color;
        if (index < equipInfo.JiAttrID.Length)
        {
            propertyId = equipInfo.JiAttrID[index];
            value = equipInfo.JiAttrValue[index];
            color = UIHelper.GetUIColor(quality > 3 ? (quality == 4 ? TextColType.White : TextColType.Gray) : TextColType.Green, true);
            preText = Language.Get("ShenEquipText3");
            newimg.SetActiveIL(quality == 4);
        }
        else if (index < (equipInfo.JiAttrID.Length + equipInfo.XianAttrID.Length))
        {
            index = index - equipInfo.JiAttrID.Length;
            propertyId = equipInfo.XianAttrID[index];
            value = equipInfo.XianAttrValue[index];
            color = UIHelper.GetUIColor(quality > 2 ? (quality == 3 ? TextColType.White : TextColType.Gray) : TextColType.Green, true);
            preText = Language.Get("ShenEquipText2");
            newimg.SetActiveIL(quality == 3);
        }
        else
        {
            index = index - equipInfo.JiAttrID.Length - equipInfo.XianAttrID.Length;
            propertyId = equipInfo.ShenAttrID[index];
            value = equipInfo.ShenAttrValue[index];
            color = UIHelper.GetUIColor(quality > 1 ? (quality == 2 ? TextColType.White : TextColType.Gray) : TextColType.Green, true);
            preText = Language.Get("ShenEquipText1");
            newimg.SetActiveIL(quality == 2);
        }
 
        pro.text = preText + PlayerPropertyConfig.GetFullDescription(propertyId, value);
        pro.color = color;
    }
 
}