少年修仙传客户端代码仓库
client_Wu Xijin
2019-06-13 033958214c0b16d7e7b93cc821b018c295251867
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
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
//--------------------------------------------------------
//    [Author]:           第二世界
//    [  Date ]:           Tuesday, August 21, 2018
//--------------------------------------------------------
using UnityEngine;
using System.Collections;
using UnityEngine.UI;
using System.Collections.Generic;
using System;
 
//神兽强化(神兽属性展示)
namespace Snxxz.UI
{
 
    public class GodBeastAttributes : MonoBehaviour
    {
        [SerializeField] ItemCell m_ItemCell;
        [SerializeField] GameObject m_FrameNull;
        [SerializeField] GameObject m_FullLevel;
        [SerializeField] GameObject m_BottomDisplay;
        [SerializeField] Text m_LvNowText;
        [SerializeField] Text m_LvNextText;
 
        [SerializeField] IntensifySmoothSlider m_ExpSlider;
        [SerializeField] Text m_ExpNum;
 
        [SerializeField] Text m_TextAttributes1;
        [SerializeField] Text m_TextAttributesAdd1;
        [SerializeField] Text m_TextAttributes2;
        [SerializeField] Text m_TextAttributesAdd2;
        [SerializeField] GodBeastSlidingList m_GodBeastSlidingList;
 
        [SerializeField] Toggle m_DoubleToggle;
        [SerializeField] Button m_StrengthenBtn;
 
        [SerializeField] UIAlphaTween m_UIAlphaTween;
        [SerializeField] Slider m_Slider;
 
        [SerializeField] GameObject m_Text_two;//下级属性
        [SerializeField] Button m_StrengthenDoubleBtn;//双倍强化按钮
        [SerializeField] Text m_NeedFairy;//所需的仙玉
        [SerializeField] GameObject m_BottomBox;
 
        [SerializeField] Text m_Text_Attributes3;
        [SerializeField] Text m_Text_Attributes4;
        DogzModel Dogz_model;
        DogzModel dogz_model { get { return Dogz_model ?? (Dogz_model = ModelCenter.Instance.GetModel<DogzModel>()); } }
        PackModel _playerPack;
        PackModel playerPack { get { return _playerPack ?? (_playerPack = ModelCenter.Instance.GetModel<PackModel>()); } }
        
        GodBeastModel godBeastModel { get { return ModelCenter.Instance.GetModel<GodBeastModel>(); } }
        private int GodBeastNumber = 0;//神兽编号
        private int GodBeastPart = 0;//神兽装备ID
 
        private int DogZLv = 0;//获取神兽等级
        private int DogZExp = 0;//熟练度
 
        private ItemModel m_DogZItemModel = null;
        private int SingleProficiency = 0;//单倍熟练度
        private int DoubleProficiency = 0;//双倍熟练度
        private int NeedFairyJade = 0;//所需仙玉
        private void Start()
        {
            m_DoubleToggle.onValueChanged.AddListener(OnClickToggle);
            m_StrengthenBtn.AddListener(OnClickStrengthBtn);
            m_StrengthenDoubleBtn.AddListener(OnClickStrengthBtn);
        }
        private void OnEnable()
        {
            if (m_DoubleToggle.isOn)
            {
                m_DoubleToggle.isOn = false;
                godBeastModel.IsToggleBool = false;
            }
            GodBeastReinforcementWin.ChooseToModify += ChooseToModify;
            godBeastModel.AbsorbEvent += AbsorbEvent;
            m_Text_Attributes3.gameObject.SetActive(false);
            m_Text_Attributes4.gameObject.SetActive(false);
        }
        private void OnDisable()
        {
            GodBeast_Number = 0;
            GodBeast_Part = 0;
 
            GodBeastReinforcementWin.ChooseToModify -= ChooseToModify;
            godBeastModel.AbsorbEvent -= AbsorbEvent;
        }
 
        public void Init()
        {
        }
 
        public void Unit()
        {
 
        }
 
        private void OnClickToggle(bool Isbool)
        {
            godBeastModel.IsToggleBool = Isbool;
            if (GodBeastNumber != 0 && GodBeastPart != 0)
            {
                AttributeAssignment();
            }
 
        }
        private void OnClickStrengthBtn()
        {
            Dictionary<int, int> DicAb = godBeastModel.Absorption_Dic;
            List<int> ListIndex = new List<int>();
            List<int> ListCount = new List<int>();
            foreach (var key in DicAb.Keys)
            {
                ListIndex.Add(key);
                ListCount.Add(DicAb[key]);
            }
            if (m_DoubleToggle.isOn)//双倍强化
            {
                DoubleStrength(ListIndex, ListCount);
            }
            else//单倍强化
            {
                SingleStrength(ListIndex, ListCount);//单倍强化
            }
        }
 
 
        private void SingleStrength(List<int> ListIndex, List<int> ListCount)//单倍强化
        {
            if (ListIndex.Count <= 0)
            {
                return;
            }
            if (godBeastModel.IsNeedEquipment())
            {
                ConfirmCancel.ShowPopConfirm(Language.Get("Mail101"), Language.Get("DogzStrengConfirm"), (bool isOk) =>
                {
                    if (isOk)
                    {
                        dogz_model.SendDogzEquipStrength(m_DogZItemModel.gridIndex, ListIndex, ListCount, 0);
                    }
                });
            }
            else
            {
                dogz_model.SendDogzEquipStrength(m_DogZItemModel.gridIndex, ListIndex, ListCount, 0);
            }
 
        }
 
        private void DoubleStrength(List<int> ListIndex, List<int> ListCount)//双倍强化
        {
            if (ListIndex.Count <= 0)
            {
                return;
            }
            if (NeedFairyJade <= 0)//所需仙玉为0时
            {
                if (godBeastModel.IsNeedEquipment())
                {
                    ConfirmCancel.ShowPopConfirm(Language.Get("Mail101"), Language.Get("DogzStrengConfirm"), (bool isOk) =>
                    {
                        if (isOk)
                        {
                            dogz_model.SendDogzEquipStrength(m_DogZItemModel.gridIndex, ListIndex, ListCount, 0);
                        }
                    });
                }
                else
                {
                    dogz_model.SendDogzEquipStrength(m_DogZItemModel.gridIndex, ListIndex, ListCount, 0);
                }
            }
            else//所需仙玉不为0时
            {
                int Gold = (int)UIHelper.GetMoneyCnt(1);//仙玉
                string strNull = string.Format(Language.Get("DogzDoubleRemind"), NeedFairyJade);
                if (godBeastModel.IsNeedEquipment())
                {
                    ConfirmCancel.ShowPopConfirm(Language.Get("Mail101"), Language.Get("DogzStrengConfirm"), (bool isOk) =>
                    {
                        if (isOk)
                        {
                            ConfirmCancel.ShowPopConfirm(Language.Get("Mail101"), strNull, (bool is_Ok) =>
                            {
                                if (is_Ok)
                                {
                                    if (Gold >= NeedFairyJade)
                                    {
                                        dogz_model.SendDogzEquipStrength(m_DogZItemModel.gridIndex, ListIndex, ListCount, 1);
                                    }
                                    else
                                    {
                                        if (VersionConfig.Get().isBanShu)
                                        {
                                            SysNotifyMgr.Instance.ShowTip("GoldErr");
                                            return;
                                        }
                                        WindowCenter.Instance.Open<RechargeTipWin>();
                                    }
                                }
                            });
                        }
                    });
                }
                else
                {
                    ConfirmCancel.ShowPopConfirm(Language.Get("Mail101"), strNull, (bool isOk) =>
                    {
                        if (isOk)
                        {
                            if (Gold >= NeedFairyJade)
                            {
                                dogz_model.SendDogzEquipStrength(m_DogZItemModel.gridIndex, ListIndex, ListCount, 1);
                            }
                            else
                            {
                                if (VersionConfig.Get().isBanShu)
                                {
                                    SysNotifyMgr.Instance.ShowTip("GoldErr");
                                    return;
                                }
                                WindowCenter.Instance.Open<RechargeTipWin>();
                            }
                        }
                    });
                }
 
            }
 
 
        }
        private void ChooseToModify(int locationMarker)
        {
            GetGodBeastLocationMarker(locationMarker);
        }
        private void AbsorbEvent()//选中与取消的数据刷新
        {
            GetDogZLevelAndExp();
            AttributeAssignment();
        }
        public void GetGodBeastLocationMarker(int LocationMarker)//获取神兽装备的标记信息
        {
            if (LocationMarker != 0)
            {
                m_ItemCell.gameObject.SetActive(true);
                GodBeastNumber = LocationMarker % 100;//神兽编号
                GodBeastPart = LocationMarker / 100;//神兽装备位ID
                List<ItemModel> itemModel = dogz_model.GetDogzEquips(GodBeastNumber);
                if (itemModel != null)
                {
                    for (int i = 0; i < itemModel.Count; i++)
                    {
                        if (itemModel[i].config.EquipPlace == GodBeastPart)
                        {
                            ItemCellModel ItemModel = new ItemCellModel(itemModel[i].itemId, true, 0);//默认显示不上锁
                            m_ItemCell.Init(ItemModel);
                            m_ItemCell.button.RemoveAllListeners();
                            int type = i;
                            m_ItemCell.button.AddListener(() =>
                            {
                                ItemTipUtility.Show(itemModel[type].guid);
                            });
                        }
                    }
                }
                m_UIAlphaTween.gameObject.SetActive(true);
                m_FrameNull.SetActive(true);
                m_FullLevel.SetActive(false);
                GetDogZLevelAndExp();
                AttributeAssignment();
            }
            else
            {
                GodBeastNumber = 0;
                GodBeastPart = 0;
                m_ItemCell.gameObject.SetActive(false);
                m_ExpSlider.stage = 0;
                m_ExpSlider.delay = 0f;
                m_ExpSlider.ResetStage();
                m_ExpSlider.value = 0;
                m_ExpNum.text = "0/0";
                m_TextAttributes1.gameObject.SetActive(false);
                m_TextAttributes2.gameObject.SetActive(false);
                m_TextAttributesAdd1.gameObject.SetActive(false);
                m_TextAttributesAdd2.gameObject.SetActive(false);
                m_StrengthenDoubleBtn.gameObject.SetActive(false);
                m_Text_two.SetActive(false);
                m_FrameNull.SetActive(false);
                m_FullLevel.SetActive(false);
                m_UIAlphaTween.gameObject.SetActive(false);
                m_BottomBox.SetActive(false);
                m_Text_Attributes3.gameObject.SetActive(false);
                m_Text_Attributes4.gameObject.SetActive(false);
            }
        }
 
        public void AttributeAssignment()
        {
            if (m_DogZItemModel == null)
            {
                return;
            }
            GainProficiency();//获取熟练度
            m_BottomBox.SetActive(true);
            var IudetDogzEquipPlus = m_DogZItemModel.GetUseData((int)ItemUseDataKey.dogzEquipPlus);
            if (IudetDogzEquipPlus != null)
            {
                int lv = godBeastModel.QualityLimit[m_DogZItemModel.config.ItemColor];
                var DogzEquipConfig = DogzEquipPlusConfig.GetEquipplaceAndLevel(GodBeastPart, lv);
                if (DogZLv >= lv)
                {
                    m_BottomBox.SetActive(false);
                    m_Text_two.SetActive(false);
                    m_FrameNull.SetActive(false);
                    FullLevelAttributes();//设置满级属性
                    m_FullLevel.SetActive(true);
                    GodBeast_Number = GodBeastNumber;
                    GodBeast_Part = GodBeastPart;
                    m_ExpSlider.stage = lv;
                    m_ExpSlider.delay = 0f;
                    m_ExpSlider.ResetStage();
                    m_ExpSlider.value = 1;
                    m_Slider.gameObject.SetActive(false);
                    int NeedExp = 0;
                    if (DogZLv > 0)
                    {
                        var Dogz_EquipConfig_1 = DogzEquipPlusConfig.GetEquipplaceAndLevel(GodBeastPart, DogZLv - 1);
                        var Dogz_EquipConfig_2 = DogzEquipPlusConfig.GetEquipplaceAndLevel(GodBeastPart, DogZLv - 2);
                        NeedExp = Dogz_EquipConfig_1.upExpTotal - Dogz_EquipConfig_2.upExpTotal;
                    }
                    m_ExpNum.text = NeedExp + "/" + NeedExp;
                }
                else
                {
                    m_Text_Attributes3.gameObject.SetActive(false);
                    m_Text_Attributes4.gameObject.SetActive(false);
                    m_StrengthenDoubleBtn.interactable = true;
                    m_StrengthenBtn.interactable = true;
                    m_Text_two.SetActive(true);
                    if (m_DoubleToggle.isOn)
                    {
                        m_StrengthenBtn.gameObject.SetActive(false);
                        m_StrengthenDoubleBtn.gameObject.SetActive(true);
                        m_NeedFairy.text = NeedFairyJade.ToString();
                        PropertySetting(DogZExp, DoubleProficiency);
                    }
                    else
                    {
                        m_StrengthenBtn.gameObject.SetActive(true);
                        m_StrengthenDoubleBtn.gameObject.SetActive(false);
                        PropertySetting(DogZExp, SingleProficiency);
                    }
                }
            }
            else
            {
                m_Text_Attributes3.gameObject.SetActive(false);
                m_Text_Attributes4.gameObject.SetActive(false);
                if (m_DoubleToggle.isOn)
                {
                    m_StrengthenBtn.gameObject.SetActive(false);
                    m_StrengthenDoubleBtn.gameObject.SetActive(true);
                    m_NeedFairy.text = NeedFairyJade.ToString();
                    PropertySetting(0, DoubleProficiency);
                }
                else
                {
                    m_StrengthenBtn.gameObject.SetActive(true);
                    m_StrengthenDoubleBtn.gameObject.SetActive(false);
                    PropertySetting(0, SingleProficiency);
                }
            }
        }
        private void GainProficiency()//选中装备的获取熟练度
        {
            SingleProficiency = 0;
            DoubleProficiency = 0;
            NeedFairyJade = 0;
            Dictionary<int, int> DicAb = godBeastModel.Absorption_Dic;
            foreach (var key in DicAb.Keys)
            {
                ItemModel itemModel = playerPack.GetItemByIndex(PackType.DogzItem, key);
                if (itemModel != null)
                {
                    if (itemModel.config.Effect1 == 235)
                    {
                        var IudetDogzEquipPlus = itemModel.GetUseData((int)ItemUseDataKey.dogzEquipPlus);
                        SingleProficiency += itemModel.config.EffectValueA1 * DicAb[key];
                        if (IudetDogzEquipPlus != null)
                        {
                            SingleProficiency += IudetDogzEquipPlus[1];
                            DoubleProficiency += IudetDogzEquipPlus[1] + itemModel.config.EffectValueA1;
                        }
                        else
                        {
                            DoubleProficiency += itemModel.config.EffectValueA1 * 2 * DicAb[key];
                            NeedFairyJade += itemModel.config.EffectValueB1 * DicAb[key];
                        }
                    }
                }
            }
 
        }
        private void PropertySetting(int ExpTotalNow, int ToExpTotal)//属性设置
        {
            m_FrameNull.gameObject.SetActive(true);
            m_FullLevel.SetActive(false);
            int toLv = ToLv(ToExpTotal);
            m_LvNowText.text = "+" + DogZLv.ToString();
            if (toLv <= DogZLv)
            {
                m_LvNextText.text = "+" + (DogZLv + 1).ToString();
                toLv = DogZLv + 1;
            }
            else
            {
                m_LvNextText.text = "+" + toLv.ToString();
            }
            var DogzEquipConfig = DogzEquipPlusConfig.GetEquipplaceAndLevel(GodBeastPart, DogZLv);
            int NeedExp = DogzEquipConfig.upExpTotal;
            if (DogZLv > 0)
            {
                var Dogz_EquipConfig = DogzEquipPlusConfig.GetEquipplaceAndLevel(GodBeastPart, DogZLv - 1);
                NeedExp -= Dogz_EquipConfig.upExpTotal;
            }
            int[] AttType = DogzEquipConfig.attType;
            int[] AttValue = DogzEquipConfig.attValue;
            if (ToExpTotal == 0)
            {
                m_Slider.gameObject.SetActive(false);
                m_TextAttributesAdd1.gameObject.SetActive(false);
                m_TextAttributesAdd2.gameObject.SetActive(false);
 
                m_ExpNum.text = DogZExp + "/" + NeedExp;
                float value = (float)DogZExp / NeedExp;
                SetExperienceBar(DogZLv, value);
                if (AttType.Length > 1)
                {
                    m_TextAttributes1.gameObject.SetActive(true);
                    m_TextAttributes2.gameObject.SetActive(true);
                    string StrName1 = PlayerPropertyConfig.Get(AttType[0]).Name;
                    string StrName2 = PlayerPropertyConfig.Get(AttType[1]).Name;
                    m_TextAttributes1.text = StrName1 + ":" + AttValue[0];
                    m_TextAttributes2.text = StrName2 + ":" + AttValue[1];
                }
                else
                {
                    m_TextAttributes2.gameObject.SetActive(false);
                    string StrName1 = PlayerPropertyConfig.Get(AttType[0]).Name;
                    m_TextAttributes1.text = StrName1 + ":" + AttValue[0];
                }
            }
            else
            {
                m_Slider.gameObject.SetActive(true);
                if (DogZExp + ToExpTotal >= NeedExp)
                {
                    m_Slider.value = 1f;
                }
                else
                {
                    m_Slider.value = (float)(DogZExp + ToExpTotal) / (float)(NeedExp);
                }
                m_UIAlphaTween.Play();
                string strColor = string.Format(Language.Get("DogzGreenText"), ToExpTotal);
                m_ExpNum.text = DogZExp + strColor + "/" + NeedExp;
                float value = (float)DogZExp / NeedExp;
                SetExperienceBar(DogZLv, value);
            }
            SetAddAttributes(DogzEquipConfig, GodBeastPart, toLv);//设置预览的属性
            if (ToExpTotal == 0)
            {
                m_StrengthenBtn.interactable = false;
                m_StrengthenDoubleBtn.interactable = false;
            }
            else
            {
                m_StrengthenBtn.interactable = true;
                m_StrengthenDoubleBtn.interactable = true;
            }
        }
 
        private int ToLv(int ToExpTotal)//获取等到达的熟练度等级
        {
            int DogzLv = 0;
            if (m_DogZItemModel == null)
            {
                return DogzLv;
            }
            int lv = godBeastModel.QualityLimit[m_DogZItemModel.config.ItemColor];
            var IudetDogzEquipPlus = m_DogZItemModel.GetUseData((int)ItemUseDataKey.dogzEquipPlus);
            if (IudetDogzEquipPlus != null && IudetDogzEquipPlus.Count > 1)
            {
                ToExpTotal += IudetDogzEquipPlus[1];
            }
            for (int i = lv; i >= 0; i--)
            {
                var DogzEquipConfig = DogzEquipPlusConfig.GetEquipplaceAndLevel(GodBeastPart, i);
                if (ToExpTotal < DogzEquipConfig.upExpTotal)
                {
                    DogzLv = DogzEquipConfig.level;
                }
            }
            var DogzEquipMaxConfig = DogzEquipPlusConfig.GetEquipplaceAndLevel(GodBeastPart, lv);
            if (ToExpTotal >= DogzEquipMaxConfig.upExpTotal)
            {
                DogzLv = DogzEquipMaxConfig.level;
            }
            return DogzLv;
        }
 
        private void GetDogZLevelAndExp()//获取当前所选选择神兽的等级和熟练度
        {
            DogZLv = 0;
            DogZExp = 0;
            m_DogZItemModel = null;
            List<ItemModel> itemModel = dogz_model.GetDogzEquips(GodBeastNumber);
            ItemModel ItemModel = null;
            if (itemModel != null)
            {
                for (int i = 0; i < itemModel.Count; i++)
                {
                    if (itemModel[i].config.EquipPlace == GodBeastPart)
                    {
                        ItemModel = itemModel[i];
                    }
                }
            }
            if (ItemModel == null)
            {
                return;
            }
            m_DogZItemModel = ItemModel;
            var IudetDogzEquipPlus = ItemModel.GetUseData((int)ItemUseDataKey.dogzEquipPlus);
            if (IudetDogzEquipPlus != null && IudetDogzEquipPlus.Count > 1)
            {
                DogZLv = IudetDogzEquipPlus[0];
                if (DogZLv > 0)
                {
                    var Dogz_EquipConfig = DogzEquipPlusConfig.GetEquipplaceAndLevel(GodBeastPart, DogZLv - 1);
                    DogZExp = IudetDogzEquipPlus[1] - Dogz_EquipConfig.upExpTotal;
                }
                else
                {
                    DogZExp = IudetDogzEquipPlus[1];
                }
 
            }
        }
 
 
        int GodBeast_Number = 0;
        int GodBeast_Part = 0;
        private void SetExperienceBar(int lv, float value)//设置经验条
        {
            if (GodBeast_Number != GodBeastNumber || GodBeast_Part != GodBeastPart)
            {
                GodBeast_Number = GodBeastNumber;
                GodBeast_Part = GodBeastPart;
                m_ExpSlider.stage = lv;
                m_ExpSlider.delay = 0f;
                m_ExpSlider.ResetStage();
                m_ExpSlider.value = value;
            }
            else
            {
                m_ExpSlider.delay = 0.1f;
                m_ExpSlider.stage = lv;
                m_ExpSlider.value = value;
            }
        }
 
        private void SetAddAttributes(DogzEquipPlusConfig DogzEquipConfig, int GodBeastPart, int toLv)//设置预览的属性
        {
            int[] AttType = DogzEquipConfig.attType;
            int[] AttValue = DogzEquipConfig.attValue;
            var DogzEquipToConfig = DogzEquipPlusConfig.GetEquipplaceAndLevel(GodBeastPart, toLv);
            int[] AttTypeTo = DogzEquipToConfig.attType;
            int[] AttValueTo = DogzEquipToConfig.attValue;
            if (AttType.Length > 1)
            {
                m_TextAttributes1.gameObject.SetActive(true);
                m_TextAttributes2.gameObject.SetActive(true);
                m_TextAttributesAdd1.gameObject.SetActive(true);
                m_TextAttributesAdd2.gameObject.SetActive(true);
                string StrName1 = PlayerPropertyConfig.Get(AttType[0]).Name;
                string StrName2 = PlayerPropertyConfig.Get(AttType[1]).Name;
                m_TextAttributes1.text = StrName1 + ":" + AttValue[0];
                m_TextAttributes2.text = StrName2 + ":" + AttValue[1];
                m_TextAttributesAdd1.text = "+" + (AttValueTo[0] - AttValue[0]);
                m_TextAttributesAdd2.text = "+" + (AttValueTo[1] - AttValue[1]);
            }
            else
            {
                m_TextAttributes1.gameObject.SetActive(true);
                m_TextAttributesAdd1.gameObject.SetActive(true);
                m_TextAttributes2.gameObject.SetActive(false);
                m_TextAttributesAdd2.gameObject.SetActive(false);
                string StrName1 = PlayerPropertyConfig.Get(AttType[0]).Name;
                m_TextAttributes1.text = StrName1 + ":" + AttValue[0];
                m_TextAttributesAdd1.text = "+" + (AttValueTo[0] - AttValue[0]);
            }
 
        }
        private void FullLevelAttributes()//设置满级属性
        {
            m_TextAttributes1.gameObject.SetActive(false);
            m_TextAttributesAdd1.gameObject.SetActive(false);
            m_TextAttributes2.gameObject.SetActive(false);
            m_TextAttributesAdd2.gameObject.SetActive(false);
            var DogzEquipConfig = DogzEquipPlusConfig.GetEquipplaceAndLevel(GodBeastPart, DogZLv);
            int[] AttType = DogzEquipConfig.attType;
            int[] AttValue = DogzEquipConfig.attValue;
            if (AttType.Length > 1)
            {
                m_Text_Attributes3.gameObject.SetActive(true);
                m_Text_Attributes4.gameObject.SetActive(true);
                string StrName1 = PlayerPropertyConfig.Get(AttType[0]).Name;
                string StrName2 = PlayerPropertyConfig.Get(AttType[1]).Name;
                m_Text_Attributes3.text = StrName1 + ":" + AttValue[0];
                m_Text_Attributes4.text = StrName2 + ":" + AttValue[1];
            }
            else
            {
                m_Text_Attributes3.gameObject.SetActive(true);
                m_Text_Attributes4.gameObject.SetActive(false);
                string StrName1 = PlayerPropertyConfig.Get(AttType[0]).Name;
                m_Text_Attributes3.text = StrName1 + ":" + AttValue[0];
            }
        }
    }
 
}