//------------------------------------------------------------------------------ // // This code was generated by a tool. // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. // //------------------------------------------------------------------------------ using Bright.Serialization; using System.Collections.Generic; using SimpleJSON; namespace cfg { public sealed partial class EventLuckyCardsMain : Bright.Config.BeanBase { public JSONNode json; public EventLuckyCardsMain(JSONNode _json) { { if(!_json["ID"].IsNumber) { throw new SerializationException(); } ID = _json["ID"]; } { if(!_json["Title"]["key"].IsString) { throw new SerializationException(); } Title_l10n_key = _json["Title"]["key"]; if(!_json["Title"]["text"].IsString) { throw new SerializationException(); } Title = _json["Title"]["text"]; } { if(!_json["Prefab"].IsString) { throw new SerializationException(); } Prefab = _json["Prefab"]; } { if(!_json["TaskPrefab"].IsString) { throw new SerializationException(); } TaskPrefab = _json["TaskPrefab"]; } { if(!_json["Icon"].IsString) { throw new SerializationException(); } Icon = _json["Icon"]; } { if(!_json["InfoPanel"].IsString) { throw new SerializationException(); } InfoPanel = _json["InfoPanel"]; } { if(!_json["Item"].IsNumber) { throw new SerializationException(); } Item = _json["Item"]; } { if(!_json["PackId"].IsNumber) { throw new SerializationException(); } PackId = _json["PackId"]; } { var __json0 = _json["WishPrize"]; if(!__json0.IsArray) { throw new SerializationException(); } WishPrize = new System.Collections.Generic.List(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { int __v0; { if(!__e0.IsNumber) { throw new SerializationException(); } __v0 = __e0; } WishPrize.Add(__v0); } } { var __json0 = _json["MilestoneList"]; if(!__json0.IsArray) { throw new SerializationException(); } MilestoneList = new System.Collections.Generic.List(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { int __v0; { if(!__e0.IsNumber) { throw new SerializationException(); } __v0 = __e0; } MilestoneList.Add(__v0); } } { var __json0 = _json["MilestoneRewardList"]; if(!__json0.IsArray) { throw new SerializationException(); } MilestoneRewardList = new System.Collections.Generic.List(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { int __v0; { if(!__e0.IsNumber) { throw new SerializationException(); } __v0 = __e0; } MilestoneRewardList.Add(__v0); } } { if(!_json["MaxMultipleCardsCount"].IsNumber) { throw new SerializationException(); } MaxMultipleCardsCount = _json["MaxMultipleCardsCount"]; } { var __json0 = _json["TaskRound1"]; if(!__json0.IsArray) { throw new SerializationException(); } TaskRound1 = new System.Collections.Generic.List(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { int __v0; { if(!__e0.IsNumber) { throw new SerializationException(); } __v0 = __e0; } TaskRound1.Add(__v0); } } { var __json0 = _json["TaskRound2"]; if(!__json0.IsArray) { throw new SerializationException(); } TaskRound2 = new System.Collections.Generic.List(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { int __v0; { if(!__e0.IsNumber) { throw new SerializationException(); } __v0 = __e0; } TaskRound2.Add(__v0); } } { var __json0 = _json["RandomSeedRound1"]; if(!__json0.IsArray) { throw new SerializationException(); } RandomSeedRound1 = new System.Collections.Generic.List(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { int __v0; { if(!__e0.IsNumber) { throw new SerializationException(); } __v0 = __e0; } RandomSeedRound1.Add(__v0); } } json = _json; PostInit(); } public EventLuckyCardsMain(int ID, string Title, string Prefab, string TaskPrefab, string Icon, string InfoPanel, int Item, int PackId, System.Collections.Generic.List WishPrize, System.Collections.Generic.List MilestoneList, System.Collections.Generic.List MilestoneRewardList, int MaxMultipleCardsCount, System.Collections.Generic.List TaskRound1, System.Collections.Generic.List TaskRound2, System.Collections.Generic.List RandomSeedRound1 ) { this.ID = ID; this.Title = Title; this.Prefab = Prefab; this.TaskPrefab = TaskPrefab; this.Icon = Icon; this.InfoPanel = InfoPanel; this.Item = Item; this.PackId = PackId; this.WishPrize = WishPrize; this.MilestoneList = MilestoneList; this.MilestoneRewardList = MilestoneRewardList; this.MaxMultipleCardsCount = MaxMultipleCardsCount; this.TaskRound1 = TaskRound1; this.TaskRound2 = TaskRound2; this.RandomSeedRound1 = RandomSeedRound1; PostInit(); } public static EventLuckyCardsMain DeserializeEventLuckyCardsMain(JSONNode _json) { return new EventLuckyCardsMain(_json); } public int ID { get; private set; } /// /// key /// public string Title { get; private set; } public string Title_l10n_key { get; } public string Prefab { get; private set; } public string TaskPrefab { get; private set; } public string Icon { get; private set; } public string InfoPanel { get; private set; } public int Item { get; private set; } /// /// 读shop表 /// public int PackId { get; private set; } /// /// 读Drop /// public System.Collections.Generic.List WishPrize { get; private set; } public System.Collections.Generic.List MilestoneList { get; private set; } /// /// 读Drop /// public System.Collections.Generic.List MilestoneRewardList { get; private set; } /// /// 最多出现几张倍率牌 /// public int MaxMultipleCardsCount { get; private set; } public System.Collections.Generic.List TaskRound1 { get; private set; } public System.Collections.Generic.List TaskRound2 { get; private set; } public System.Collections.Generic.List RandomSeedRound1 { get; private set; } public const int __ID__ = -1495158066; public override int GetTypeId() => __ID__; public void Resolve(Dictionary _tables) { PostResolve(); } public void TranslateText(System.Func translator) { Title = translator(Title_l10n_key, Title); } public override string ToString() { return "{ " + "ID:" + ID + "," + "Title:" + Title + "," + "Prefab:" + Prefab + "," + "TaskPrefab:" + TaskPrefab + "," + "Icon:" + Icon + "," + "InfoPanel:" + InfoPanel + "," + "Item:" + Item + "," + "PackId:" + PackId + "," + "WishPrize:" + Bright.Common.StringUtil.CollectionToString(WishPrize) + "," + "MilestoneList:" + Bright.Common.StringUtil.CollectionToString(MilestoneList) + "," + "MilestoneRewardList:" + Bright.Common.StringUtil.CollectionToString(MilestoneRewardList) + "," + "MaxMultipleCardsCount:" + MaxMultipleCardsCount + "," + "TaskRound1:" + Bright.Common.StringUtil.CollectionToString(TaskRound1) + "," + "TaskRound2:" + Bright.Common.StringUtil.CollectionToString(TaskRound2) + "," + "RandomSeedRound1:" + Bright.Common.StringUtil.CollectionToString(RandomSeedRound1) + "," + "}"; } partial void PostInit(); partial void PostResolve(); } }