//------------------------------------------------------------------------------ // // 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.MonsterCfg { public sealed partial class DataMonster : Bright.Config.BeanBase { public DataMonster(JSONNode _json) { { if(!_json["MonsterID"].IsNumber) { throw new SerializationException(); } MonsterID = _json["MonsterID"]; } { if(!_json["MonsterClassID"].IsNumber) { throw new SerializationException(); } MonsterClassID = _json["MonsterClassID"]; } { if(!_json["AttackFix"].IsNumber) { throw new SerializationException(); } AttackFix = _json["AttackFix"]; } { if(!_json["HPFix"].IsNumber) { throw new SerializationException(); } HPFix = _json["HPFix"]; } { if(!_json["ShieldFix"].IsNumber) { throw new SerializationException(); } ShieldFix = _json["ShieldFix"]; } { if(!_json["DefenceFix"].IsNumber) { throw new SerializationException(); } DefenceFix = _json["DefenceFix"]; } { if(!_json["FindEnemyRange"].IsNumber) { throw new SerializationException(); } FindEnemyRange = _json["FindEnemyRange"]; } PostInit(); } public DataMonster(int MonsterID, int MonsterClassID, float AttackFix, float HPFix, float ShieldFix, float DefenceFix, int FindEnemyRange ) { this.MonsterID = MonsterID; this.MonsterClassID = MonsterClassID; this.AttackFix = AttackFix; this.HPFix = HPFix; this.ShieldFix = ShieldFix; this.DefenceFix = DefenceFix; this.FindEnemyRange = FindEnemyRange; PostInit(); } public static DataMonster DeserializeDataMonster(JSONNode _json) { return new MonsterCfg.DataMonster(_json); } /// /// 怪物ID /// public int MonsterID { get; private set; } /// /// 怪物类ID /// public int MonsterClassID { get; private set; } /// /// 怪物攻击关卡修正 /// public float AttackFix { get; private set; } /// /// 怪物血量关卡修正 /// public float HPFix { get; private set; } /// /// 怪物护盾关卡修正 /// public float ShieldFix { get; private set; } /// /// 怪物防御关卡修正 /// public float DefenceFix { get; private set; } /// /// 索敌范围 /// public int FindEnemyRange { get; private set; } public const int __ID__ = 1610052364; public override int GetTypeId() => __ID__; public void Resolve(Dictionary _tables) { PostResolve(); } public void TranslateText(System.Func translator) { } public override string ToString() { return "{ " + "MonsterID:" + MonsterID + "," + "MonsterClassID:" + MonsterClassID + "," + "AttackFix:" + AttackFix + "," + "HPFix:" + HPFix + "," + "ShieldFix:" + ShieldFix + "," + "DefenceFix:" + DefenceFix + "," + "FindEnemyRange:" + FindEnemyRange + "," + "}"; } partial void PostInit(); partial void PostResolve(); } }