//--------------------------------------------------------
|
// [Author]: 第二世界
|
// [ Date ]: Tuesday, February 12, 2019
|
//--------------------------------------------------------
|
|
using UnityEngine;
|
using System;
|
|
namespace TableConfig {
|
|
|
public partial class MapResourcesConfig : ConfigBase {
|
|
public int ID;
|
public int DataID;
|
public int LineID;
|
public string Name;
|
public string BigMap;
|
public Vector3 MapScale;
|
public float MapShowScale;
|
public string MapResources;
|
public Vector3 MapOffset;
|
public int[] Effect;
|
public int Music;
|
public int ShowBOSSTime;
|
|
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);
|
|
int.TryParse(contents[1],out DataID);
|
|
int.TryParse(contents[2],out LineID);
|
|
Name = contents[3];
|
|
BigMap = contents[4];
|
|
MapScale=contents[5].Vector3Parse();
|
|
float.TryParse(contents[6],out MapShowScale);
|
|
MapResources = contents[7];
|
|
MapOffset=contents[8].Vector3Parse();
|
|
var EffectStringArray = contents[9].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries);
|
Effect = new int[EffectStringArray.Length];
|
for (int i=0;i<EffectStringArray.Length;i++)
|
{
|
int.TryParse(EffectStringArray[i],out Effect[i]);
|
}
|
|
int.TryParse(contents[10],out Music);
|
|
int.TryParse(contents[11],out ShowBOSSTime);
|
}
|
catch (Exception ex)
|
{
|
DebugEx.Log(ex);
|
}
|
}
|
|
}
|
|
}
|
|
|
|
|