| | |
| | | using System; |
| | | using UnityEngine; |
| | | |
| | | [XLua.LuaCallCSharp] |
| | | |
| | | public partial class SpiritWeaponConfig |
| | | { |
| | | |
| | | public readonly int ItemID;
|
| | | public readonly int Level;
|
| | | public readonly int[] AttrIDList;
|
| | | public readonly int[] AttrValueList;
|
| | | public readonly int[] AttrColorList;
|
| | | public readonly int AttrScore;
|
| | | public readonly Int2[] UpCostItem;
|
| | | public readonly int NextItemID;
|
| | | public readonly int NPCID;
|
| | | public readonly Vector3 Rotation;
|
| | | public readonly float scale;
|
| | | public readonly int ItemID; |
| | | public readonly int Level; |
| | | public readonly int[] AttrIDList; |
| | | public readonly int[] AttrValueList; |
| | | public readonly int[] AttrColorList; |
| | | public readonly int AttrScore; |
| | | public readonly Int2[] UpCostItem; |
| | | public readonly int NextItemID; |
| | | public readonly int NPCID; |
| | | public readonly Vector3 Rotation; |
| | | public readonly float scale; |
| | | public readonly Vector3 RawImgPos; |
| | | |
| | | public SpiritWeaponConfig() |
| | |
| | | { |
| | | var tables = input.Split('\t'); |
| | | |
| | | int.TryParse(tables[0],out ItemID); |
| | |
|
| | | int.TryParse(tables[1],out Level); |
| | |
|
| | | int.TryParse(tables[0],out ItemID); |
| | | |
| | | int.TryParse(tables[1],out Level); |
| | | |
| | | string[] AttrIDListStringArray = tables[2].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries); |
| | | AttrIDList = new int[AttrIDListStringArray.Length]; |
| | | for (int i=0;i<AttrIDListStringArray.Length;i++) |
| | | { |
| | | int.TryParse(AttrIDListStringArray[i],out AttrIDList[i]); |
| | | }
|
| | |
|
| | | } |
| | | |
| | | string[] AttrValueListStringArray = tables[3].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries); |
| | | AttrValueList = new int[AttrValueListStringArray.Length]; |
| | | for (int i=0;i<AttrValueListStringArray.Length;i++) |
| | | { |
| | | int.TryParse(AttrValueListStringArray[i],out AttrValueList[i]); |
| | | }
|
| | |
|
| | | } |
| | | |
| | | string[] AttrColorListStringArray = tables[4].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries); |
| | | AttrColorList = new int[AttrColorListStringArray.Length]; |
| | | for (int i=0;i<AttrColorListStringArray.Length;i++) |
| | | { |
| | | int.TryParse(AttrColorListStringArray[i],out AttrColorList[i]); |
| | | }
|
| | |
|
| | | int.TryParse(tables[5],out AttrScore); |
| | |
|
| | | } |
| | | |
| | | int.TryParse(tables[5],out AttrScore); |
| | | |
| | | string[] UpCostItemStringArray = tables[6].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries); |
| | | UpCostItem = new Int2[UpCostItemStringArray.Length]; |
| | | for (int i=0;i<UpCostItemStringArray.Length;i++) |
| | | { |
| | | Int2.TryParse(UpCostItemStringArray[i],out UpCostItem[i]); |
| | | }
|
| | |
|
| | | int.TryParse(tables[7],out NextItemID); |
| | |
|
| | | int.TryParse(tables[8],out NPCID); |
| | |
|
| | | Rotation=tables[9].Vector3Parse();
|
| | |
|
| | | float.TryParse(tables[10],out scale); |
| | |
|
| | | } |
| | | |
| | | int.TryParse(tables[7],out NextItemID); |
| | | |
| | | int.TryParse(tables[8],out NPCID); |
| | | |
| | | Rotation=tables[9].Vector3Parse(); |
| | | |
| | | float.TryParse(tables[10],out scale); |
| | | |
| | | RawImgPos=tables[11].Vector3Parse(); |
| | | } |
| | | catch (Exception ex) |