少年修仙传客户端代码仓库
client_Wu Xijin
2019-01-22 301753e85218375dcbe4c1138d0f161ccdcc89da
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
//--------------------------------------------------------
//    [Author]:            第二世界
//    [  Date ]:           Tuesday, January 22, 2019
//--------------------------------------------------------
 
using UnityEngine;
using System;
 
namespace TableConfig {
 
    
    public partial class JadeDynastyTowerConfig : ConfigBase {
 
        public int floorId { get ; private set ; }
        public int floorIndex { get ; private set ; }
        public string floorName { get ; private set; } 
        public int[] rewardIdsLevelS;
        public int[] rewardCountsLevelS;
        public int[] rewardIdsLevelA;
        public int[] rewardCountsLevelA;
        public int[] rewardIdsLevelB;
        public int[] rewardCountsLevelB;
        public int unLockEquipPlace { get ; private set ; }
        public string specialRewardDescription { get ; private set; } 
        public int fightPower { get ; private set ; }
 
        public override string getKey()
        {
            return floorId.ToString();
        }
 
        public override void Parse() {
            try
            {
                floorId=IsNumeric(rawContents[0]) ? int.Parse(rawContents[0]):0; 
            
                floorIndex=IsNumeric(rawContents[1]) ? int.Parse(rawContents[1]):0; 
            
                floorName = rawContents[2].Trim();
            
                string[] rewardIdsLevelSStringArray = rawContents[3].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries);
                rewardIdsLevelS = new int[rewardIdsLevelSStringArray.Length];
                for (int i=0;i<rewardIdsLevelSStringArray.Length;i++)
                {
                     int.TryParse(rewardIdsLevelSStringArray[i],out rewardIdsLevelS[i]);
                }
            
                string[] rewardCountsLevelSStringArray = rawContents[4].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries);
                rewardCountsLevelS = new int[rewardCountsLevelSStringArray.Length];
                for (int i=0;i<rewardCountsLevelSStringArray.Length;i++)
                {
                     int.TryParse(rewardCountsLevelSStringArray[i],out rewardCountsLevelS[i]);
                }
            
                string[] rewardIdsLevelAStringArray = rawContents[5].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries);
                rewardIdsLevelA = new int[rewardIdsLevelAStringArray.Length];
                for (int i=0;i<rewardIdsLevelAStringArray.Length;i++)
                {
                     int.TryParse(rewardIdsLevelAStringArray[i],out rewardIdsLevelA[i]);
                }
            
                string[] rewardCountsLevelAStringArray = rawContents[6].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries);
                rewardCountsLevelA = new int[rewardCountsLevelAStringArray.Length];
                for (int i=0;i<rewardCountsLevelAStringArray.Length;i++)
                {
                     int.TryParse(rewardCountsLevelAStringArray[i],out rewardCountsLevelA[i]);
                }
            
                string[] rewardIdsLevelBStringArray = rawContents[7].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries);
                rewardIdsLevelB = new int[rewardIdsLevelBStringArray.Length];
                for (int i=0;i<rewardIdsLevelBStringArray.Length;i++)
                {
                     int.TryParse(rewardIdsLevelBStringArray[i],out rewardIdsLevelB[i]);
                }
            
                string[] rewardCountsLevelBStringArray = rawContents[8].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries);
                rewardCountsLevelB = new int[rewardCountsLevelBStringArray.Length];
                for (int i=0;i<rewardCountsLevelBStringArray.Length;i++)
                {
                     int.TryParse(rewardCountsLevelBStringArray[i],out rewardCountsLevelB[i]);
                }
            
                unLockEquipPlace=IsNumeric(rawContents[9]) ? int.Parse(rawContents[9]):0; 
            
                specialRewardDescription = rawContents[10].Trim();
            
                fightPower=IsNumeric(rawContents[11]) ? int.Parse(rawContents[11]):0; 
            }
            catch (Exception ex)
            {
                DebugEx.Log(ex);
            }
        }
    
    }
 
}