//------------------------------------------------------------------------------ // // 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.EmojCfg { public sealed partial class DataEmoji : Bright.Config.BeanBase { public DataEmoji(JSONNode _json) { { if(!_json["ID"].IsNumber) { throw new SerializationException(); } ID = _json["ID"]; } { if(!_json["BgImg"].IsString) { throw new SerializationException(); } BgImg = _json["BgImg"]; } { if(!_json["UpImg"].IsString) { throw new SerializationException(); } UpImg = _json["UpImg"]; } { if(!_json["MidImg"].IsString) { throw new SerializationException(); } MidImg = _json["MidImg"]; } { if(!_json["DownImg"].IsString) { throw new SerializationException(); } DownImg = _json["DownImg"]; } { var __json0 = _json["EffectIds"]; if(!__json0.IsArray) { throw new SerializationException(); } EffectIds = new System.Collections.Generic.List(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { int __v0; { if(!__e0.IsNumber) { throw new SerializationException(); } __v0 = __e0; } EffectIds.Add(__v0); } } PostInit(); } public DataEmoji(int ID, string BgImg, string UpImg, string MidImg, string DownImg, System.Collections.Generic.List EffectIds ) { this.ID = ID; this.BgImg = BgImg; this.UpImg = UpImg; this.MidImg = MidImg; this.DownImg = DownImg; this.EffectIds = EffectIds; PostInit(); } public static DataEmoji DeserializeDataEmoji(JSONNode _json) { return new EmojCfg.DataEmoji(_json); } /// /// 配置用ID /// public int ID { get; private set; } /// /// 底片图片 /// public string BgImg { get; private set; } /// /// 上图片-眉毛 /// public string UpImg { get; private set; } /// /// 中图片-眼镜 /// public string MidImg { get; private set; } /// /// 下图片-嘴巴 /// public string DownImg { get; private set; } /// /// 特效 /// public System.Collections.Generic.List EffectIds { get; private set; } public const int __ID__ = -276976209; public override int GetTypeId() => __ID__; public void Resolve(Dictionary _tables) { PostResolve(); } public void TranslateText(System.Func translator) { } public override string ToString() { return "{ " + "ID:" + ID + "," + "BgImg:" + BgImg + "," + "UpImg:" + UpImg + "," + "MidImg:" + MidImg + "," + "DownImg:" + DownImg + "," + "EffectIds:" + Bright.Common.StringUtil.CollectionToString(EffectIds) + "," + "}"; } partial void PostInit(); partial void PostResolve(); } }