| | |
| | | //-------------------------------------------------------- |
| | | // [Author]: 第二世界 |
| | | // [ Date ]: Friday, September 21, 2018 |
| | | //-------------------------------------------------------- |
| | | |
| | | using UnityEngine; |
| | | using System; |
| | | |
| | | namespace TableConfig { |
| | | |
| | | |
| | | public partial class DogzConfig : ConfigBase { |
| | | |
| | | public int ID { get ; private set ; }
|
| | | public string Name { get ; private set; } |
| | | public string HeadIcon { get ; private set; } |
| | | //--------------------------------------------------------
|
| | | // [Author]: 第二世界
|
| | | // [ Date ]: Tuesday, February 12, 2019
|
| | | //--------------------------------------------------------
|
| | |
|
| | | using UnityEngine;
|
| | | using System;
|
| | |
|
| | | namespace TableConfig {
|
| | |
|
| | | |
| | | public partial class DogzConfig : ConfigBase {
|
| | |
|
| | | public int ID;
|
| | | public string Name;
|
| | | public string HeadIcon;
|
| | | public int[] BaseAttrTypes;
|
| | | public int[] BaseAttrValues;
|
| | | public int[] HelpBattleSkills;
|
| | | public int FightPowerEx { get ; private set ; }
|
| | | public int[] EquipPlaceColorList; |
| | | |
| | | public override string getKey() |
| | | { |
| | | return ID.ToString(); |
| | | } |
| | | |
| | | public override void Parse() { |
| | | try |
| | | { |
| | | ID=IsNumeric(rawContents[0]) ? int.Parse(rawContents[0]):0; |
| | | public int FightPowerEx;
|
| | | public int[] EquipPlaceColorList;
|
| | |
|
| | | public override string getKey()
|
| | | {
|
| | | return ID.ToString();
|
| | | }
|
| | |
|
| | | public override void Parse(string content) {
|
| | | try
|
| | | {
|
| | | var contents = content.Split('\t');
|
| | |
|
| | | int.TryParse(contents[0],out ID);
|
| | |
|
| | | Name = rawContents[1].Trim();
|
| | | Name = contents[1];
|
| | |
|
| | | HeadIcon = rawContents[2].Trim();
|
| | | HeadIcon = contents[2];
|
| | |
|
| | | string[] BaseAttrTypesStringArray = rawContents[3].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries); |
| | | var BaseAttrTypesStringArray = contents[3].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries); |
| | | BaseAttrTypes = new int[BaseAttrTypesStringArray.Length]; |
| | | for (int i=0;i<BaseAttrTypesStringArray.Length;i++) |
| | | { |
| | | int.TryParse(BaseAttrTypesStringArray[i],out BaseAttrTypes[i]); |
| | | }
|
| | |
|
| | | string[] BaseAttrValuesStringArray = rawContents[4].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries); |
| | | var BaseAttrValuesStringArray = contents[4].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries); |
| | | BaseAttrValues = new int[BaseAttrValuesStringArray.Length]; |
| | | for (int i=0;i<BaseAttrValuesStringArray.Length;i++) |
| | | { |
| | | int.TryParse(BaseAttrValuesStringArray[i],out BaseAttrValues[i]); |
| | | }
|
| | |
|
| | | string[] HelpBattleSkillsStringArray = rawContents[5].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries); |
| | | var HelpBattleSkillsStringArray = contents[5].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries); |
| | | HelpBattleSkills = new int[HelpBattleSkillsStringArray.Length]; |
| | | for (int i=0;i<HelpBattleSkillsStringArray.Length;i++) |
| | | { |
| | | int.TryParse(HelpBattleSkillsStringArray[i],out HelpBattleSkills[i]); |
| | | }
|
| | |
|
| | | FightPowerEx=IsNumeric(rawContents[6]) ? int.Parse(rawContents[6]):0; |
| | | int.TryParse(contents[6],out FightPowerEx);
|
| | |
|
| | | string[] EquipPlaceColorListStringArray = rawContents[7].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries); |
| | | var EquipPlaceColorListStringArray = contents[7].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries); |
| | | EquipPlaceColorList = new int[EquipPlaceColorListStringArray.Length]; |
| | | for (int i=0;i<EquipPlaceColorListStringArray.Length;i++) |
| | | { |
| | | int.TryParse(EquipPlaceColorListStringArray[i],out EquipPlaceColorList[i]); |
| | | } |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | | DebugEx.Log(ex); |
| | | } |
| | | } |
| | | |
| | | } |
| | | |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | }
|
| | | }
|
| | | catch (Exception ex)
|
| | | {
|
| | | DebugEx.Log(ex);
|
| | | }
|
| | | }
|
| | | |
| | | }
|
| | |
|
| | | }
|
| | |
|
| | |
|
| | |
|
| | |
|