//--------------------------------------------------------
|
// [Author]: 第二世界
|
// [ Date ]: Friday, April 20, 2018
|
//--------------------------------------------------------
|
|
using UnityEngine;
|
using System;
|
|
namespace TableConfig {
|
|
|
public partial class RealmPracticeConfig : ConfigBase {
|
|
public int ID { get ; private set ; }
|
public int Type { get ; private set ; }
|
public string FirstTypeName { get ; private set; }
|
public int SecondType { get ; private set ; }
|
public string SecondTypeName { get ; private set; }
|
public int[] AchieveID;
|
public int FunctionID { get ; private set ; }
|
public string Icon { get ; private set; }
|
|
public override string getKey()
|
{
|
return ID.ToString();
|
}
|
|
public override void Parse() {
|
try
|
{
|
ID=IsNumeric(rawContents[0]) ? int.Parse(rawContents[0]):0;
|
|
Type=IsNumeric(rawContents[1]) ? int.Parse(rawContents[1]):0;
|
|
FirstTypeName = rawContents[2].Trim();
|
|
SecondType=IsNumeric(rawContents[3]) ? int.Parse(rawContents[3]):0;
|
|
SecondTypeName = rawContents[4].Trim();
|
|
string[] AchieveIDStringArray = rawContents[5].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries);
|
AchieveID = new int[AchieveIDStringArray.Length];
|
for (int i=0;i<AchieveIDStringArray.Length;i++)
|
{
|
int.TryParse(AchieveIDStringArray[i],out AchieveID[i]);
|
}
|
|
FunctionID=IsNumeric(rawContents[6]) ? int.Parse(rawContents[6]):0;
|
|
Icon = rawContents[7].Trim();
|
}
|
catch (Exception ex)
|
{
|
DebugEx.Log(ex);
|
}
|
}
|
|
}
|
|
}
|