//------------------------------------------------------------------------------ // // 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 DataCondition : Bright.Config.BeanBase { public DataCondition(JSONNode _json) { { if(!_json["Id"].IsNumber) { throw new SerializationException(); } Id = _json["Id"]; } { if(!_json["Type"].IsNumber) { throw new SerializationException(); } Type = (ConditionType)_json["Type"].AsInt; } { if(!_json["Param1"].IsNumber) { throw new SerializationException(); } Param1 = _json["Param1"]; } { if(!_json["Param2"].IsNumber) { throw new SerializationException(); } Param2 = _json["Param2"]; } { if(!_json["Param3"].IsNumber) { throw new SerializationException(); } Param3 = _json["Param3"]; } PostInit(); } public DataCondition(int Id, ConditionType Type, int Param1, int Param2, int Param3 ) { this.Id = Id; this.Type = Type; this.Param1 = Param1; this.Param2 = Param2; this.Param3 = Param3; PostInit(); } public static DataCondition DeserializeDataCondition(JSONNode _json) { return new DataCondition(_json); } /// /// 解锁ID /// public int Id { get; private set; } /// /// 解锁类型 /// public ConditionType Type { get; private set; } /// /// 参数1 /// public int Param1 { get; private set; } /// /// 参数2 /// public int Param2 { get; private set; } /// /// 参数3 /// public int Param3 { get; private set; } public const int __ID__ = -1867658127; public override int GetTypeId() => __ID__; public void Resolve(Dictionary _tables) { PostResolve(); } public void TranslateText(System.Func translator) { } public override string ToString() { return "{ " + "Id:" + Id + "," + "Type:" + Type + "," + "Param1:" + Param1 + "," + "Param2:" + Param2 + "," + "Param3:" + Param3 + "," + "}"; } partial void PostInit(); partial void PostResolve(); } }