//------------------------------------------------------------------------------ // // 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 EventSoloRobotBehavior : Bright.Config.BeanBase { public JSONNode json; public EventSoloRobotBehavior(JSONNode _json) { { if(!_json["ID"].IsNumber) { throw new SerializationException(); } ID = _json["ID"]; } { if(!_json["Weight"].IsNumber) { throw new SerializationException(); } Weight = _json["Weight"]; } { var __json0 = _json["Start"]; if(!__json0.IsArray) { throw new SerializationException(); } Start = new System.Collections.Generic.List>(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { System.Collections.Generic.List __v0; { var __json1 = __e0; if(!__json1.IsArray) { throw new SerializationException(); } __v0 = new System.Collections.Generic.List(__json1.Count); foreach(JSONNode __e1 in __json1.Children) { int __v1; { if(!__e1.IsNumber) { throw new SerializationException(); } __v1 = __e1; } __v0.Add(__v1); } } Start.Add(__v0); } } { var __json0 = _json["FishingSuccess"]; if(!__json0.IsArray) { throw new SerializationException(); } FishingSuccess = new System.Collections.Generic.List>(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { System.Collections.Generic.List __v0; { var __json1 = __e0; if(!__json1.IsArray) { throw new SerializationException(); } __v0 = new System.Collections.Generic.List(__json1.Count); foreach(JSONNode __e1 in __json1.Children) { int __v1; { if(!__e1.IsNumber) { throw new SerializationException(); } __v1 = __e1; } __v0.Add(__v1); } } FishingSuccess.Add(__v0); } } { var __json0 = _json["OpponetFishingSuccess"]; if(!__json0.IsArray) { throw new SerializationException(); } OpponetFishingSuccess = new System.Collections.Generic.List>(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { System.Collections.Generic.List __v0; { var __json1 = __e0; if(!__json1.IsArray) { throw new SerializationException(); } __v0 = new System.Collections.Generic.List(__json1.Count); foreach(JSONNode __e1 in __json1.Children) { int __v1; { if(!__e1.IsNumber) { throw new SerializationException(); } __v1 = __e1; } __v0.Add(__v1); } } OpponetFishingSuccess.Add(__v0); } } { var __json0 = _json["OpponetFishingFail"]; if(!__json0.IsArray) { throw new SerializationException(); } OpponetFishingFail = new System.Collections.Generic.List>(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { System.Collections.Generic.List __v0; { var __json1 = __e0; if(!__json1.IsArray) { throw new SerializationException(); } __v0 = new System.Collections.Generic.List(__json1.Count); foreach(JSONNode __e1 in __json1.Children) { int __v1; { if(!__e1.IsNumber) { throw new SerializationException(); } __v1 = __e1; } __v0.Add(__v1); } } OpponetFishingFail.Add(__v0); } } { var __json0 = _json["FirstLastFishStart"]; if(!__json0.IsArray) { throw new SerializationException(); } FirstLastFishStart = new System.Collections.Generic.List>(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { System.Collections.Generic.List __v0; { var __json1 = __e0; if(!__json1.IsArray) { throw new SerializationException(); } __v0 = new System.Collections.Generic.List(__json1.Count); foreach(JSONNode __e1 in __json1.Children) { int __v1; { if(!__e1.IsNumber) { throw new SerializationException(); } __v1 = __e1; } __v0.Add(__v1); } } FirstLastFishStart.Add(__v0); } } { var __json0 = _json["FirstLastFishSuccess"]; if(!__json0.IsArray) { throw new SerializationException(); } FirstLastFishSuccess = new System.Collections.Generic.List>(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { System.Collections.Generic.List __v0; { var __json1 = __e0; if(!__json1.IsArray) { throw new SerializationException(); } __v0 = new System.Collections.Generic.List(__json1.Count); foreach(JSONNode __e1 in __json1.Children) { int __v1; { if(!__e1.IsNumber) { throw new SerializationException(); } __v1 = __e1; } __v0.Add(__v1); } } FirstLastFishSuccess.Add(__v0); } } { var __json0 = _json["EndVictory"]; if(!__json0.IsArray) { throw new SerializationException(); } EndVictory = new System.Collections.Generic.List>(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { System.Collections.Generic.List __v0; { var __json1 = __e0; if(!__json1.IsArray) { throw new SerializationException(); } __v0 = new System.Collections.Generic.List(__json1.Count); foreach(JSONNode __e1 in __json1.Children) { int __v1; { if(!__e1.IsNumber) { throw new SerializationException(); } __v1 = __e1; } __v0.Add(__v1); } } EndVictory.Add(__v0); } } { var __json0 = _json["EndDefeat"]; if(!__json0.IsArray) { throw new SerializationException(); } EndDefeat = new System.Collections.Generic.List>(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { System.Collections.Generic.List __v0; { var __json1 = __e0; if(!__json1.IsArray) { throw new SerializationException(); } __v0 = new System.Collections.Generic.List(__json1.Count); foreach(JSONNode __e1 in __json1.Children) { int __v1; { if(!__e1.IsNumber) { throw new SerializationException(); } __v1 = __e1; } __v0.Add(__v1); } } EndDefeat.Add(__v0); } } json = _json; PostInit(); } public EventSoloRobotBehavior(int ID, int Weight, System.Collections.Generic.List> Start, System.Collections.Generic.List> FishingSuccess, System.Collections.Generic.List> OpponetFishingSuccess, System.Collections.Generic.List> OpponetFishingFail, System.Collections.Generic.List> FirstLastFishStart, System.Collections.Generic.List> FirstLastFishSuccess, System.Collections.Generic.List> EndVictory, System.Collections.Generic.List> EndDefeat ) { this.ID = ID; this.Weight = Weight; this.Start = Start; this.FishingSuccess = FishingSuccess; this.OpponetFishingSuccess = OpponetFishingSuccess; this.OpponetFishingFail = OpponetFishingFail; this.FirstLastFishStart = FirstLastFishStart; this.FirstLastFishSuccess = FirstLastFishSuccess; this.EndVictory = EndVictory; this.EndDefeat = EndDefeat; PostInit(); } public static EventSoloRobotBehavior DeserializeEventSoloRobotBehavior(JSONNode _json) { return new EventSoloRobotBehavior(_json); } public int ID { get; private set; } public int Weight { get; private set; } /// /// 对决开始 /// public System.Collections.Generic.List> Start { get; private set; } /// /// 成功钓鱼 /// public System.Collections.Generic.List> FishingSuccess { get; private set; } /// /// 对手钓鱼成功 /// public System.Collections.Generic.List> OpponetFishingSuccess { get; private set; } /// /// 对手钓鱼失败 /// public System.Collections.Generic.List> OpponetFishingFail { get; private set; } /// /// 先开始钓最后一条鱼 /// public System.Collections.Generic.List> FirstLastFishStart { get; private set; } /// /// 先钓完最后一条鱼 /// public System.Collections.Generic.List> FirstLastFishSuccess { get; private set; } /// /// 对决结算-胜利 /// public System.Collections.Generic.List> EndVictory { get; private set; } /// /// 对决结算-失败 /// public System.Collections.Generic.List> EndDefeat { get; private set; } public const int __ID__ = -434989853; public override int GetTypeId() => __ID__; public void Resolve(Dictionary _tables) { PostResolve(); } public void TranslateText(System.Func translator) { } public override string ToString() { return "{ " + "ID:" + ID + "," + "Weight:" + Weight + "," + "Start:" + Bright.Common.StringUtil.CollectionToString(Start) + "," + "FishingSuccess:" + Bright.Common.StringUtil.CollectionToString(FishingSuccess) + "," + "OpponetFishingSuccess:" + Bright.Common.StringUtil.CollectionToString(OpponetFishingSuccess) + "," + "OpponetFishingFail:" + Bright.Common.StringUtil.CollectionToString(OpponetFishingFail) + "," + "FirstLastFishStart:" + Bright.Common.StringUtil.CollectionToString(FirstLastFishStart) + "," + "FirstLastFishSuccess:" + Bright.Common.StringUtil.CollectionToString(FirstLastFishSuccess) + "," + "EndVictory:" + Bright.Common.StringUtil.CollectionToString(EndVictory) + "," + "EndDefeat:" + Bright.Common.StringUtil.CollectionToString(EndDefeat) + "," + "}"; } partial void PostInit(); partial void PostResolve(); } }