//------------------------------------------------------------------------------ // // 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 Luban; using SimpleJSON; namespace cfg.BlacksmithData { public sealed partial class WeaponData : Luban.BeanBase { public WeaponData(JSONNode _buf) { { if(!_buf["ID"].IsNumber) { throw new SerializationException(); } ID = _buf["ID"]; } { if(!_buf["Name"].IsString) { throw new SerializationException(); } Name = _buf["Name"]; } { var __json0 = _buf["Include"]; if(!__json0.IsArray) { throw new SerializationException(); } Include = new System.Collections.Generic.List(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { int __v0; { if(!__e0.IsNumber) { throw new SerializationException(); } __v0 = __e0; } Include.Add(__v0); } } { if(!_buf["Level"].IsNumber) { throw new SerializationException(); } Level = _buf["Level"]; } { if(!_buf["Levelmax"].IsNumber) { throw new SerializationException(); } Levelmax = _buf["Levelmax"]; } { if(!_buf["Levelup"].IsNumber) { throw new SerializationException(); } Levelup = _buf["Levelup"]; } { if(!_buf["Icon"].IsString) { throw new SerializationException(); } Icon = _buf["Icon"]; } { if(!_buf["Describe"].IsString) { throw new SerializationException(); } Describe = _buf["Describe"]; } } public static WeaponData DeserializeWeaponData(JSONNode _buf) { return new BlacksmithData.WeaponData(_buf); } /// /// ID /// public readonly int ID; /// /// 名称 /// public readonly string Name; /// /// 包含的武器名称 /// public readonly System.Collections.Generic.List Include; /// /// 初始等级 /// public readonly int Level; /// /// 最高等级 /// public readonly int Levelmax; /// /// 升级调用ID /// public readonly int Levelup; /// /// 界面图标名称 /// public readonly string Icon; /// /// 培养界面内的描述 /// public readonly string Describe; public const int __ID__ = 898518182; public override int GetTypeId() => __ID__; public void ResolveRef(Tables tables) { } public override string ToString() { return "{ " + "ID:" + ID + "," + "Name:" + Name + "," + "Include:" + Luban.StringUtil.CollectionToString(Include) + "," + "Level:" + Level + "," + "Levelmax:" + Levelmax + "," + "Levelup:" + Levelup + "," + "Icon:" + Icon + "," + "Describe:" + Describe + "," + "}"; } } }