| | |
| | | //-------------------------------------------------------- |
| | | // [Author]: 第二世界 |
| | | // [ Date ]: Saturday, July 28, 2018 |
| | | // [ Date ]: Monday, January 28, 2019 |
| | | //-------------------------------------------------------- |
| | | |
| | | using UnityEngine; |
| | |
| | | namespace TableConfig { |
| | | |
| | | |
| | | public partial class RedPackConfig : ConfigBase {
|
| | |
|
| | | public partial class RedPackConfig : ConfigBase { |
| | | |
| | | public int id { get ; private set ; }
|
| | | public int RedEnvelopeType { get ; private set ; }
|
| | | public int RedEnvelopeAmount { get ; private set ; }
|
| | |
| | | public int PacketCnt { get ; private set ; }
|
| | | public int LeaderOwn { get ; private set ; }
|
| | | public string content { get ; private set; }
|
| | | public string PacketOpenTime { get ; private set; } |
| | | public int ValidMinutes { get ; private set ; } |
| | | |
| | | public override string getKey()
|
| | | {
|
| | | return id.ToString();
|
| | | public override string getKey() |
| | | { |
| | | return id.ToString(); |
| | | } |
| | | |
| | | public override void Parse() { |
| | | try
|
| | | {
|
| | | try |
| | | { |
| | | id=IsNumeric(rawContents[0]) ? int.Parse(rawContents[0]):0;
|
| | |
|
| | | RedEnvelopeType=IsNumeric(rawContents[1]) ? int.Parse(rawContents[1]):0;
|
| | |
| | | LeaderOwn=IsNumeric(rawContents[5]) ? int.Parse(rawContents[5]):0;
|
| | |
|
| | | content = rawContents[6].Trim();
|
| | | }
|
| | | catch (Exception ex)
|
| | | {
|
| | | DebugEx.Log(ex);
|
| | | |
| | | PacketOpenTime = rawContents[7].Trim();
|
| | | |
| | | ValidMinutes=IsNumeric(rawContents[8]) ? int.Parse(rawContents[8]):0; |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | | DebugEx.Log(ex); |
| | | } |
| | | } |
| | | |