| | |
| | | //-------------------------------------------------------- |
| | | // [Author]: 第二世界 |
| | | // [ Date ]: Thursday, September 20, 2018 |
| | | //-------------------------------------------------------- |
| | | |
| | | using UnityEngine; |
| | | using System; |
| | | |
| | | namespace TableConfig { |
| | | |
| | | |
| | | public partial class TreasurePrivilegeConfig : ConfigBase { |
| | | |
| | | public int PrivilegeID { get ; private set ; }
|
| | | public string Description { get ; private set; } |
| | | public string EffectValue { get ; private set; } |
| | | public int singleValue { get ; private set ; }
|
| | | public int maxValue { get ; private set ; }
|
| | | public string attr { get ; private set; } |
| | | public string itemAward { get ; private set; } |
| | | //--------------------------------------------------------
|
| | | // [Author]: 第二世界
|
| | | // [ Date ]: Tuesday, February 12, 2019
|
| | | //--------------------------------------------------------
|
| | |
|
| | | using UnityEngine;
|
| | | using System;
|
| | |
|
| | | namespace TableConfig {
|
| | |
|
| | | |
| | | public partial class TreasurePrivilegeConfig : ConfigBase {
|
| | |
|
| | | public int PrivilegeID;
|
| | | public string Description;
|
| | | public string EffectValue;
|
| | | public int singleValue;
|
| | | public int maxValue;
|
| | | public string attr;
|
| | | public string itemAward;
|
| | | public int[] successList;
|
| | | public int treasureId { get ; private set ; }
|
| | | public int sort { get ; private set ; }
|
| | | public string Icon { get ; private set; } |
| | | public string Name { get ; private set; } |
| | | public string targetDescription { get ; private set; } |
| | | public int effectId { get ; private set ; } |
| | | |
| | | public override string getKey() |
| | | { |
| | | return PrivilegeID.ToString(); |
| | | } |
| | | |
| | | public override void Parse() { |
| | | try |
| | | { |
| | | PrivilegeID=IsNumeric(rawContents[0]) ? int.Parse(rawContents[0]):0; |
| | | public int treasureId;
|
| | | public int sort;
|
| | | public string Icon;
|
| | | public string Name;
|
| | | public string targetDescription;
|
| | | public int effectId;
|
| | |
|
| | | public override string getKey()
|
| | | {
|
| | | return PrivilegeID.ToString();
|
| | | }
|
| | |
|
| | | public override void Parse(string content) {
|
| | | try
|
| | | {
|
| | | var contents = content.Split('\t');
|
| | |
|
| | | int.TryParse(contents[0],out PrivilegeID);
|
| | |
|
| | | Description = rawContents[1].Trim();
|
| | | Description = contents[1];
|
| | |
|
| | | EffectValue = rawContents[2].Trim();
|
| | | EffectValue = contents[2];
|
| | |
|
| | | singleValue=IsNumeric(rawContents[3]) ? int.Parse(rawContents[3]):0; |
| | | int.TryParse(contents[3],out singleValue);
|
| | |
|
| | | maxValue=IsNumeric(rawContents[4]) ? int.Parse(rawContents[4]):0; |
| | | int.TryParse(contents[4],out maxValue);
|
| | |
|
| | | attr = rawContents[5].Trim();
|
| | | attr = contents[5];
|
| | |
|
| | | itemAward = rawContents[6].Trim();
|
| | | itemAward = contents[6];
|
| | |
|
| | | string[] successListStringArray = rawContents[7].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries); |
| | | var successListStringArray = contents[7].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries); |
| | | successList = new int[successListStringArray.Length]; |
| | | for (int i=0;i<successListStringArray.Length;i++) |
| | | { |
| | | int.TryParse(successListStringArray[i],out successList[i]); |
| | | }
|
| | |
|
| | | treasureId=IsNumeric(rawContents[8]) ? int.Parse(rawContents[8]):0; |
| | | int.TryParse(contents[8],out treasureId);
|
| | |
|
| | | sort=IsNumeric(rawContents[9]) ? int.Parse(rawContents[9]):0; |
| | | int.TryParse(contents[9],out sort);
|
| | |
|
| | | Icon = rawContents[10].Trim();
|
| | | Icon = contents[10];
|
| | |
|
| | | Name = rawContents[11].Trim();
|
| | | Name = contents[11];
|
| | |
|
| | | targetDescription = rawContents[12].Trim();
|
| | | targetDescription = contents[12];
|
| | |
|
| | | effectId=IsNumeric(rawContents[13]) ? int.Parse(rawContents[13]):0; |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | | DebugEx.Log(ex); |
| | | } |
| | | } |
| | | |
| | | } |
| | | |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | int.TryParse(contents[13],out effectId);
|
| | | }
|
| | | catch (Exception ex)
|
| | | {
|
| | | DebugEx.Log(ex);
|
| | | }
|
| | | }
|
| | | |
| | | }
|
| | |
|
| | | }
|
| | |
|
| | |
|
| | |
|
| | |
|