From 21d2a96d51021fdf07a163a816e2045e229e57c3 Mon Sep 17 00:00:00 2001 From: ALEXTANG <574809918@qq.com> Date: Tue, 11 Apr 2023 20:19:20 +0800 Subject: [PATCH] GameProto GameProto --- .gitignore | 4 + .../HotFix/GameProto/ConfigLoader.cs | 76 ++++++++++ .../HotFix/GameProto/ConfigLoader.cs.meta | 11 ++ .../HotFix/GameProto/GameConfig.meta | 8 + .../HotFix/GameProto/GameConfig/Battle.meta | 8 + .../GameConfig/Battle/ActorAttrAddType.cs | 32 ++++ .../Battle/ActorAttrAddType.cs.meta | 11 ++ .../GameConfig/Battle/ActorAttrDataType.cs | 88 +++++++++++ .../Battle/ActorAttrDataType.cs.meta | 11 ++ .../GameConfig/Battle/BuffAttrConfig.cs | 116 +++++++++++++++ .../GameConfig/Battle/BuffAttrConfig.cs.meta | 11 ++ .../GameProto/GameConfig/Battle/BuffConfig.cs | 111 ++++++++++++++ .../GameConfig/Battle/BuffConfig.cs.meta | 11 ++ .../GameConfig/Battle/BuffDotTickConfig.cs | 64 ++++++++ .../Battle/BuffDotTickConfig.cs.meta | 11 ++ .../GameConfig/Battle/BuffReplaceType.cs | 36 +++++ .../GameConfig/Battle/BuffReplaceType.cs.meta | 11 ++ .../GameConfig/Battle/BuffResultType.cs | 100 +++++++++++++ .../GameConfig/Battle/BuffResultType.cs.meta | 11 ++ .../GameConfig/Battle/BuffStateID.cs | 60 ++++++++ .../GameConfig/Battle/BuffStateID.cs.meta | 11 ++ .../GameConfig/Battle/BuffTimeType.cs | 24 +++ .../GameConfig/Battle/BuffTimeType.cs.meta | 11 ++ .../GameConfig/Battle/BuffTriggleState.cs | 64 ++++++++ .../Battle/BuffTriggleState.cs.meta | 11 ++ .../GameConfig/Battle/ResAttrImpactData.cs | 68 +++++++++ .../Battle/ResAttrImpactData.cs.meta | 11 ++ .../GameConfig/Battle/SkillAttrDamageData.cs | 80 ++++++++++ .../Battle/SkillAttrDamageData.cs.meta | 11 ++ .../GameConfig/Battle/SkillAttrDamageType.cs | 40 +++++ .../Battle/SkillAttrDamageType.cs.meta | 11 ++ .../GameConfig/Battle/SkillBaseConfig.cs | 132 +++++++++++++++++ .../GameConfig/Battle/SkillBaseConfig.cs.meta | 11 ++ .../GameConfig/Battle/SkillMagicType.cs | 28 ++++ .../GameConfig/Battle/SkillMagicType.cs.meta | 11 ++ .../GameProto/GameConfig/Battle/TbBuff.cs | 65 +++++++++ .../GameConfig/Battle/TbBuff.cs.meta | 11 ++ .../GameProto/GameConfig/Battle/TbBuffAttr.cs | 65 +++++++++ .../GameConfig/Battle/TbBuffAttr.cs.meta | 11 ++ .../GameProto/GameConfig/Battle/TbSkill.cs | 65 +++++++++ .../GameConfig/Battle/TbSkill.cs.meta | 11 ++ .../HotFix/GameProto/GameConfig/Tables.cs | 54 +++++++ .../GameProto/GameConfig/Tables.cs.meta | 11 ++ .../HotFix/GameProto/GameConfig/item.meta | 8 + .../GameProto/GameConfig/item/EQuality.cs | 32 ++++ .../GameConfig/item/EQuality.cs.meta | 11 ++ .../HotFix/GameProto/GameConfig/item/Item.cs | 138 ++++++++++++++++++ .../GameProto/GameConfig/item/Item.cs.meta | 11 ++ .../GameProto/GameConfig/item/ItemExchange.cs | 70 +++++++++ .../GameConfig/item/ItemExchange.cs.meta | 11 ++ .../GameProto/GameConfig/item/TbItem.cs | 65 +++++++++ .../GameProto/GameConfig/item/TbItem.cs.meta | 11 ++ .../HotFix/GameProto/GameConfig/test.meta | 8 + .../GameProto/GameConfig/test/AccessFlag.cs | 25 ++++ .../GameConfig/test/AccessFlag.cs.meta | 11 ++ .../HotFix/GameProto/GameProto.asmdef | 1 + 56 files changed, 2010 insertions(+) create mode 100644 Assets/GameScripts/HotFix/GameProto/ConfigLoader.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/ConfigLoader.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ActorAttrAddType.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ActorAttrAddType.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ActorAttrDataType.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ActorAttrDataType.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffAttrConfig.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffAttrConfig.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffConfig.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffConfig.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffDotTickConfig.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffDotTickConfig.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffReplaceType.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffReplaceType.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffResultType.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffResultType.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffStateID.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffStateID.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffTimeType.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffTimeType.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffTriggleState.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffTriggleState.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ResAttrImpactData.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ResAttrImpactData.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillAttrDamageData.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillAttrDamageData.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillAttrDamageType.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillAttrDamageType.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillBaseConfig.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillBaseConfig.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillMagicType.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillMagicType.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbBuff.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbBuff.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbBuffAttr.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbBuffAttr.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbSkill.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbSkill.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Tables.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/Tables.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/item.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/item/EQuality.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/item/EQuality.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/item/Item.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/item/Item.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/item/ItemExchange.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/item/ItemExchange.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/item/TbItem.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/item/TbItem.cs.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/test.meta create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/test/AccessFlag.cs create mode 100644 Assets/GameScripts/HotFix/GameProto/GameConfig/test/AccessFlag.cs.meta diff --git a/.gitignore b/.gitignore index 5c75d77e..ef012d5c 100644 --- a/.gitignore +++ b/.gitignore @@ -96,3 +96,7 @@ Assets/HybridCLRBuildCache/AssetBundleSourceData/StandaloneWindows.meta #Bundles Bundles/ + +#Luban +Luban/.cache.meta +GenerateDatas/ \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameProto/ConfigLoader.cs b/Assets/GameScripts/HotFix/GameProto/ConfigLoader.cs new file mode 100644 index 00000000..c7316578 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/ConfigLoader.cs @@ -0,0 +1,76 @@ +using Bright.Serialization; +using System.IO; +using GameBase; +using GameConfig; +using SimpleJSON; +using UnityEngine; + +/// +/// 配置加载器 +/// +public class ConfigLoader:Singleton +{ + private bool _init = false; + + private Tables _tables; + + public Tables Tables + { + get + { + if (!_init) + { + _init = true; + Load(); + } + return _tables; + } + } + + /// + /// 加载配置 + /// + public void Load() + { + var tablesCtor = typeof(Tables).GetConstructors()[0]; + var loaderReturnType = tablesCtor.GetParameters()[0].ParameterType.GetGenericArguments()[1]; + + System.Delegate loader = loaderReturnType == typeof(ByteBuf) + ? new System.Func(LoadByteBuf) + : (System.Delegate)new System.Func(LoadJson); + _tables = (Tables)tablesCtor.Invoke(new object[] { loader }); + } + + /// + /// 加载Json配置。 + /// + /// FileName + /// JSONNode + private JSONNode LoadJson(string file) + { +#if UNITY_EDITOR + var ret = File.ReadAllText($"{Application.dataPath}/../GenerateDatas/json/{file}.json", System.Text.Encoding.UTF8); +#else + var textAssets = GameModule.Resource.LoadAsset($"{SettingsUtils.FrameworkGlobalSettings.ConfigFolderName}{file}.json"); + var ret = textAssets.text; +#endif + return JSON.Parse(ret); + } + + /// + /// 加载二进制配置。 + /// + /// FileName + /// ByteBuf + private ByteBuf LoadByteBuf(string file) + { + byte[] ret = null; +#if UNITY_EDITOR + ret = File.ReadAllBytes($"{Application.dataPath}/../GenerateDatas/bytes/{file}.bytes"); +#else + var textAssets = GameModule.Resource.LoadAsset($"{SettingsUtils.FrameworkGlobalSettings.ConfigFolderName}{file}.bytes"); + ret = textAssets.bytes; +#endif + return new ByteBuf(ret); + } +} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameProto/ConfigLoader.cs.meta b/Assets/GameScripts/HotFix/GameProto/ConfigLoader.cs.meta new file mode 100644 index 00000000..605dfe9e --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/ConfigLoader.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: abc35c855bfb323429a1d72066c8489c +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig.meta new file mode 100644 index 00000000..b0f67e90 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6d0980a1bfd281147b089e41b0a4561e +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle.meta new file mode 100644 index 00000000..838c5e72 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 31f94e2989871ec49b783b3aeb1b142c +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ActorAttrAddType.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ActorAttrAddType.cs new file mode 100644 index 00000000..d3794e78 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ActorAttrAddType.cs @@ -0,0 +1,32 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + + +namespace GameConfig.Battle +{ + public enum ActorAttrAddType + { + /// + /// 无效数据 + /// + NONE = 0, + /// + /// 加法计算 + /// + ABSOLUTE_VAL = 1, + /// + /// 多个项结果累加,然后对加法做乘法 + /// + SUM_PERCENT_VAL = 2, + /// + /// 每一项都是对最终结果做乘法 + /// + MUL_PERCENT_VAL = 3, + } + +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ActorAttrAddType.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ActorAttrAddType.cs.meta new file mode 100644 index 00000000..826f0860 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ActorAttrAddType.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 073f19ae3fef26f43b193ff35a27eb9c +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ActorAttrDataType.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ActorAttrDataType.cs new file mode 100644 index 00000000..035a3060 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ActorAttrDataType.cs @@ -0,0 +1,88 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + + +namespace GameConfig.Battle +{ + public enum ActorAttrDataType + { + /// + /// 无效数据 + /// + None = 0, + /// + /// 最大血量 + /// + MaxHp = 1, + /// + /// 攻击力 + /// + Attack = 2, + /// + /// 物理伤害 + /// + PhyDamage = 3, + /// + /// 物理防御 + /// + PhyDef = 4, + /// + /// 法术伤害 + /// + MagicDamage = 5, + /// + /// 法术防御 + /// + MagicDef = 6, + /// + /// 移动速度 + /// + MoveSpeed = 7, + /// + /// 攻击速度 + /// + AttackSpeed = 8, + /// + /// 命中率 + /// + Hit = 9, + /// + /// 闪避率 + /// + Dodge = 10, + /// + /// 暴击率 + /// + CriticalAtkRatio = 11, + /// + /// San值(疯狂值) + /// + SanValue = 12, + /// + /// 最大MP + /// + MaxMp = 13, + /// + /// 物理伤害倍率 + /// + PhyDamageRatio = 14, + /// + /// 魔法伤害倍率 + /// + MagicDamageRatio = 15, + /// + /// 暴击倍率 + /// + CriticalRatio = 16, + /// + /// 暴击减免 + /// + CriticalReduce = 17, + } + +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ActorAttrDataType.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ActorAttrDataType.cs.meta new file mode 100644 index 00000000..8edd71bd --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ActorAttrDataType.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 89dbbbd30b2f8c74f86ede4e27591ba7 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffAttrConfig.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffAttrConfig.cs new file mode 100644 index 00000000..16380252 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffAttrConfig.cs @@ -0,0 +1,116 @@ +//------------------------------------------------------------------------------ +// +// 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 GameConfig.Battle +{ + +public sealed partial class BuffAttrConfig : Bright.Config.BeanBase +{ + public BuffAttrConfig(JSONNode _json) + { + { if(!_json["BuffID"].IsNumber) { throw new SerializationException(); } BuffID = _json["BuffID"]; } + { if(!_json["name"].IsString) { throw new SerializationException(); } Name = _json["name"]; } + { if(!_json["StackNum"].IsNumber) { throw new SerializationException(); } StackNum = _json["StackNum"]; } + { if(!_json["DurTime"].IsNumber) { throw new SerializationException(); } DurTime = _json["DurTime"]; } + { if(!_json["ResultType"].IsNumber) { throw new SerializationException(); } ResultType = (Battle.BuffResultType)_json["ResultType"].AsInt; } + { if(!_json["RemoveWhenDie"].IsNumber) { throw new SerializationException(); } RemoveWhenDie = _json["RemoveWhenDie"]; } + { if(!_json["DotDamageData"].IsObject) { throw new SerializationException(); } DotDamageData = Battle.SkillAttrDamageData.DeserializeSkillAttrDamageData(_json["DotDamageData"]); } + { if(!_json["DotTickConfig"].IsObject) { throw new SerializationException(); } DotTickConfig = Battle.BuffDotTickConfig.DeserializeBuffDotTickConfig(_json["DotTickConfig"]); } + { var __json0 = _json["AttrData"]; if(!__json0.IsArray) { throw new SerializationException(); } AttrData = new System.Collections.Generic.List(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { Battle.ResAttrImpactData __v0; { if(!__e0.IsObject) { throw new SerializationException(); } __v0 = Battle.ResAttrImpactData.DeserializeResAttrImpactData(__e0); } AttrData.Add(__v0); } } + PostInit(); + } + + public BuffAttrConfig(int BuffID, string name, int StackNum, float DurTime, Battle.BuffResultType ResultType, int RemoveWhenDie, Battle.SkillAttrDamageData DotDamageData, Battle.BuffDotTickConfig DotTickConfig, System.Collections.Generic.List AttrData ) + { + this.BuffID = BuffID; + this.Name = name; + this.StackNum = StackNum; + this.DurTime = DurTime; + this.ResultType = ResultType; + this.RemoveWhenDie = RemoveWhenDie; + this.DotDamageData = DotDamageData; + this.DotTickConfig = DotTickConfig; + this.AttrData = AttrData; + PostInit(); + } + + public static BuffAttrConfig DeserializeBuffAttrConfig(JSONNode _json) + { + return new Battle.BuffAttrConfig(_json); + } + + /// + /// BuffID + /// + public int BuffID { get; private set; } + /// + /// 名字 + /// + public string Name { get; private set; } + /// + /// 叠加次数 + /// + public int StackNum { get; private set; } + /// + /// 持续时间 + /// + public float DurTime { get; private set; } + /// + /// 数值效果类型 + /// + public Battle.BuffResultType ResultType { get; private set; } + /// + /// 死亡消失 + /// + public int RemoveWhenDie { get; private set; } + public Battle.SkillAttrDamageData DotDamageData { get; private set; } + public Battle.BuffDotTickConfig DotTickConfig { get; private set; } + public System.Collections.Generic.List AttrData { get; private set; } + + public const int __ID__ = 1652935996; + public override int GetTypeId() => __ID__; + + public void Resolve(Dictionary _tables) + { + DotDamageData?.Resolve(_tables); + DotTickConfig?.Resolve(_tables); + foreach(var _e in AttrData) { _e?.Resolve(_tables); } + PostResolve(); + } + + public void TranslateText(System.Func translator) + { + DotDamageData?.TranslateText(translator); + DotTickConfig?.TranslateText(translator); + foreach(var _e in AttrData) { _e?.TranslateText(translator); } + } + + public override string ToString() + { + return "{ " + + "BuffID:" + BuffID + "," + + "Name:" + Name + "," + + "StackNum:" + StackNum + "," + + "DurTime:" + DurTime + "," + + "ResultType:" + ResultType + "," + + "RemoveWhenDie:" + RemoveWhenDie + "," + + "DotDamageData:" + DotDamageData + "," + + "DotTickConfig:" + DotTickConfig + "," + + "AttrData:" + Bright.Common.StringUtil.CollectionToString(AttrData) + "," + + "}"; + } + + partial void PostInit(); + partial void PostResolve(); +} +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffAttrConfig.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffAttrConfig.cs.meta new file mode 100644 index 00000000..b2a9d28f --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffAttrConfig.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 5224da34dfb42c141b22335957c1b784 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffConfig.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffConfig.cs new file mode 100644 index 00000000..4ad4e2a7 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffConfig.cs @@ -0,0 +1,111 @@ +//------------------------------------------------------------------------------ +// +// 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 GameConfig.Battle +{ + +public sealed partial class BuffConfig : Bright.Config.BeanBase +{ + public BuffConfig(JSONNode _json) + { + { if(!_json["BuffID"].IsNumber) { throw new SerializationException(); } BuffID = _json["BuffID"]; } + { if(!_json["name"].IsString) { throw new SerializationException(); } Name = _json["name"]; } + { if(!_json["prefId"].IsNumber) { throw new SerializationException(); } PrefId = _json["prefId"]; } + { if(!_json["desc"].IsString) { throw new SerializationException(); } Desc = _json["desc"]; } + { if(!_json["icon"].IsString) { throw new SerializationException(); } Icon = _json["icon"]; } + { if(!_json["TimeType"].IsNumber) { throw new SerializationException(); } TimeType = (Battle.BuffTimeType)_json["TimeType"].AsInt; } + { if(!_json["ReplaceType"].IsNumber) { throw new SerializationException(); } ReplaceType = (Battle.BuffReplaceType)_json["ReplaceType"].AsInt; } + { if(!_json["State"].IsObject) { throw new SerializationException(); } State = Battle.BuffTriggleState.DeserializeBuffTriggleState(_json["State"]); } + PostInit(); + } + + public BuffConfig(int BuffID, string name, int prefId, string desc, string icon, Battle.BuffTimeType TimeType, Battle.BuffReplaceType ReplaceType, Battle.BuffTriggleState State ) + { + this.BuffID = BuffID; + this.Name = name; + this.PrefId = prefId; + this.Desc = desc; + this.Icon = icon; + this.TimeType = TimeType; + this.ReplaceType = ReplaceType; + this.State = State; + PostInit(); + } + + public static BuffConfig DeserializeBuffConfig(JSONNode _json) + { + return new Battle.BuffConfig(_json); + } + + /// + /// BuffID + /// + public int BuffID { get; private set; } + /// + /// 名字 + /// + public string Name { get; private set; } + /// + /// 表现ID + /// + public int PrefId { get; private set; } + /// + /// 描述 + /// + public string Desc { get; private set; } + /// + /// 图标 + /// + public string Icon { get; private set; } + /// + /// 持续类型 + /// + public Battle.BuffTimeType TimeType { get; private set; } + /// + /// 叠加类型 + /// + public Battle.BuffReplaceType ReplaceType { get; private set; } + public Battle.BuffTriggleState State { get; private set; } + + public const int __ID__ = 1807662187; + public override int GetTypeId() => __ID__; + + public void Resolve(Dictionary _tables) + { + State?.Resolve(_tables); + PostResolve(); + } + + public void TranslateText(System.Func translator) + { + State?.TranslateText(translator); + } + + public override string ToString() + { + return "{ " + + "BuffID:" + BuffID + "," + + "Name:" + Name + "," + + "PrefId:" + PrefId + "," + + "Desc:" + Desc + "," + + "Icon:" + Icon + "," + + "TimeType:" + TimeType + "," + + "ReplaceType:" + ReplaceType + "," + + "State:" + State + "," + + "}"; + } + + partial void PostInit(); + partial void PostResolve(); +} +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffConfig.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffConfig.cs.meta new file mode 100644 index 00000000..6f834efa --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffConfig.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 6b4f7b8798a4dca4ca075552d618f24d +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffDotTickConfig.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffDotTickConfig.cs new file mode 100644 index 00000000..bd5715d2 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffDotTickConfig.cs @@ -0,0 +1,64 @@ +//------------------------------------------------------------------------------ +// +// 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 GameConfig.Battle +{ + +public sealed partial class BuffDotTickConfig : Bright.Config.BeanBase +{ + public BuffDotTickConfig(JSONNode _json) + { + { if(!_json["TickTime"].IsNumber) { throw new SerializationException(); } TickTime = _json["TickTime"]; } + { if(!_json["TickWhenAdd"].IsNumber) { throw new SerializationException(); } TickWhenAdd = _json["TickWhenAdd"]; } + PostInit(); + } + + public BuffDotTickConfig(float TickTime, int TickWhenAdd ) + { + this.TickTime = TickTime; + this.TickWhenAdd = TickWhenAdd; + PostInit(); + } + + public static BuffDotTickConfig DeserializeBuffDotTickConfig(JSONNode _json) + { + return new Battle.BuffDotTickConfig(_json); + } + + public float TickTime { get; private set; } + public int TickWhenAdd { get; private set; } + + public const int __ID__ = 2124630047; + public override int GetTypeId() => __ID__; + + public void Resolve(Dictionary _tables) + { + PostResolve(); + } + + public void TranslateText(System.Func translator) + { + } + + public override string ToString() + { + return "{ " + + "TickTime:" + TickTime + "," + + "TickWhenAdd:" + TickWhenAdd + "," + + "}"; + } + + partial void PostInit(); + partial void PostResolve(); +} +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffDotTickConfig.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffDotTickConfig.cs.meta new file mode 100644 index 00000000..aa13cf5e --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffDotTickConfig.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 3b87372c0c0ce0547bc2221f8f8cc7dc +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffReplaceType.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffReplaceType.cs new file mode 100644 index 00000000..558554ce --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffReplaceType.cs @@ -0,0 +1,36 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + + +namespace GameConfig.Battle +{ + public enum BuffReplaceType + { + /// + /// 更新时间范围 + /// + BUFF_REPLACE_INSTEAD = 0, + /// + /// 不允许叠加 + /// + BUFF_REPLACE_FORBIT = 1, + /// + /// 累加时间范围 + /// + BUFF_REPLACE_ADD_TIME = 2, + /// + /// 叠加数值 + /// + BUFF_REPLACE_ADD_ATTR = 3, + /// + /// 叠加种类 + /// + BUFF_REPLACE_TYPE_COUNT = 4, + } + +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffReplaceType.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffReplaceType.cs.meta new file mode 100644 index 00000000..f7f74211 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffReplaceType.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 6141f2c1272ed3848baf1f8d3341fc79 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffResultType.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffResultType.cs new file mode 100644 index 00000000..9545d379 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffResultType.cs @@ -0,0 +1,100 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + + +namespace GameConfig.Battle +{ + public enum BuffResultType + { + /// + /// 无 + /// + BUFF_RESULT_NONE = 0, + /// + /// 物理攻击提升 + /// + BUFF_RESULT_PHY_ATK_UP = 1, + /// + /// 物理攻击降低 + /// + BUFF_RESULT_PHY_ATK_DOWN = 2, + /// + /// 物理防御提升 + /// + BUFF_RESULT_PHY_DEF_UP = 3, + /// + /// 物理防御降低 + /// + BUFF_RESULT_PHY_DEF_DOWN = 4, + /// + /// 物理命中提升 + /// + BUFF_RESULT_PHY_HIT_UP = 5, + /// + /// 物理命中降低 + /// + BUFF_RESULT_PHY_HIT_DOWN = 6, + /// + /// 物理持续掉血 + /// + BUFF_RESULT_PHY_LOSE_HP = 7, + /// + /// 法术攻击提升 + /// + BUFF_RESULT_MAG_ATK_UP = 8, + /// + /// 法术攻击降低 + /// + BUFF_RESULT_MAG_ATK_DOWN = 9, + /// + /// 法术防御提升 + /// + BUFF_RESULT_MAG_DEF_UP = 10, + /// + /// 法术防御降低 + /// + BUFF_RESULT_MAG_DEF_DOWN = 11, + /// + /// 法术命中提升 + /// + BUFF_RESULT_MAG_HIT_UP = 12, + /// + /// 法术命中降低 + /// + BUFF_RESULT_MAG_HIT_DOWN = 13, + /// + /// 法术持续掉血 + /// + BUFF_RESULT_MAG_LOSE_HP = 14, + /// + /// 暴击率提升 + /// + BUFF_RESULT_CIRT_UP = 15, + /// + /// 暴击率降低 + /// + BUFF_RESULT_CIRT_DOWN = 16, + /// + /// 暴击倍率提升 + /// + BUFF_RESULT_CIRT_VALUE_UP = 17, + /// + /// 暴击倍率降低 + /// + BUFF_RESULT_CIRT_VALUE_DOWN = 18, + /// + /// 移速提升 + /// + BUFF_RESULT_MOVE_SPEED_UP = 19, + /// + /// 移速降低 + /// + BUFF_RESULT_MOVE_SPEED_DOWN = 20, + } + +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffResultType.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffResultType.cs.meta new file mode 100644 index 00000000..c841d5f1 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffResultType.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 2e26edcf2629cd142b51031f7b81f679 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffStateID.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffStateID.cs new file mode 100644 index 00000000..bedf850f --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffStateID.cs @@ -0,0 +1,60 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + + +namespace GameConfig.Battle +{ + public enum BuffStateID + { + /// + /// 无状态 + /// + BUFF_STATE_NONE = 0, + /// + /// 眩晕状态 + /// + BUFF_STATE_STUN = 1, + /// + /// 无敌状态 + /// + BUFF_STATE_UNDEAD = 2, + /// + /// 隐身状态 + /// + BUFF_STATE_INVISIBLE = 3, + /// + /// 体形变大 + /// + BUFF_STATE_BIGGER = 4, + /// + /// 定身,不能移动 + /// + BUFF_STATE_NO_MOVE = 5, + /// + /// 沉默,不能放技能 + /// + BUFF_STATE_NO_SKILL = 6, + /// + /// 昏睡 + /// + BUFF_STATE_SLEEP = 7, + /// + /// 强制开启阻挡 + /// + BUFF_STATE_FORCE_COLLIDER = 8, + /// + /// 无视阻挡 + /// + BUFF_STATE_IGNORE_COLLIDER = 9, + /// + /// 最大状态 + /// + BUFF_STATE_MAX = 10, + } + +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffStateID.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffStateID.cs.meta new file mode 100644 index 00000000..a5949a8e --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffStateID.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 24a5cdf7ed62f5945aba3814ebf02ae8 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffTimeType.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffTimeType.cs new file mode 100644 index 00000000..5b4db5d3 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffTimeType.cs @@ -0,0 +1,24 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + + +namespace GameConfig.Battle +{ + public enum BuffTimeType + { + /// + /// 指定持续时间 + /// + BUFF_TIME_DURING = 0, + /// + /// 无尽时间 + /// + BUFF_TIME_INFINIT = 1, + } + +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffTimeType.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffTimeType.cs.meta new file mode 100644 index 00000000..fbe7142e --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffTimeType.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: dff2bf6f031b38d4c8574d94e75d28d1 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffTriggleState.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffTriggleState.cs new file mode 100644 index 00000000..f0b26eea --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffTriggleState.cs @@ -0,0 +1,64 @@ +//------------------------------------------------------------------------------ +// +// 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 GameConfig.Battle +{ + +public sealed partial class BuffTriggleState : Bright.Config.BeanBase +{ + public BuffTriggleState(JSONNode _json) + { + { if(!_json["StateID"].IsNumber) { throw new SerializationException(); } StateID = (Battle.BuffStateID)_json["StateID"].AsInt; } + { if(!_json["StateParam"].IsNumber) { throw new SerializationException(); } StateParam = _json["StateParam"]; } + PostInit(); + } + + public BuffTriggleState(Battle.BuffStateID StateID, float StateParam ) + { + this.StateID = StateID; + this.StateParam = StateParam; + PostInit(); + } + + public static BuffTriggleState DeserializeBuffTriggleState(JSONNode _json) + { + return new Battle.BuffTriggleState(_json); + } + + public Battle.BuffStateID StateID { get; private set; } + public float StateParam { get; private set; } + + public const int __ID__ = 1328146134; + public override int GetTypeId() => __ID__; + + public void Resolve(Dictionary _tables) + { + PostResolve(); + } + + public void TranslateText(System.Func translator) + { + } + + public override string ToString() + { + return "{ " + + "StateID:" + StateID + "," + + "StateParam:" + StateParam + "," + + "}"; + } + + partial void PostInit(); + partial void PostResolve(); +} +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffTriggleState.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffTriggleState.cs.meta new file mode 100644 index 00000000..124ee8aa --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/BuffTriggleState.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 03926dd0c4ff9dd479230386fd1e9190 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ResAttrImpactData.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ResAttrImpactData.cs new file mode 100644 index 00000000..17171a89 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ResAttrImpactData.cs @@ -0,0 +1,68 @@ +//------------------------------------------------------------------------------ +// +// 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 GameConfig.Battle +{ + +public sealed partial class ResAttrImpactData : Bright.Config.BeanBase +{ + public ResAttrImpactData(JSONNode _json) + { + { if(!_json["DataType"].IsNumber) { throw new SerializationException(); } DataType = (Battle.ActorAttrDataType)_json["DataType"].AsInt; } + { if(!_json["AddType"].IsNumber) { throw new SerializationException(); } AddType = (Battle.ActorAttrAddType)_json["AddType"].AsInt; } + { if(!_json["Value"].IsNumber) { throw new SerializationException(); } Value = _json["Value"]; } + PostInit(); + } + + public ResAttrImpactData(Battle.ActorAttrDataType DataType, Battle.ActorAttrAddType AddType, float Value ) + { + this.DataType = DataType; + this.AddType = AddType; + this.Value = Value; + PostInit(); + } + + public static ResAttrImpactData DeserializeResAttrImpactData(JSONNode _json) + { + return new Battle.ResAttrImpactData(_json); + } + + public Battle.ActorAttrDataType DataType { get; private set; } + public Battle.ActorAttrAddType AddType { get; private set; } + public float Value { get; private set; } + + public const int __ID__ = 1319292907; + public override int GetTypeId() => __ID__; + + public void Resolve(Dictionary _tables) + { + PostResolve(); + } + + public void TranslateText(System.Func translator) + { + } + + public override string ToString() + { + return "{ " + + "DataType:" + DataType + "," + + "AddType:" + AddType + "," + + "Value:" + Value + "," + + "}"; + } + + partial void PostInit(); + partial void PostResolve(); +} +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ResAttrImpactData.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ResAttrImpactData.cs.meta new file mode 100644 index 00000000..42d84b47 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/ResAttrImpactData.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 9d3720a9d26e66047ad302fd1dc92da5 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillAttrDamageData.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillAttrDamageData.cs new file mode 100644 index 00000000..1fd6a9a0 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillAttrDamageData.cs @@ -0,0 +1,80 @@ +//------------------------------------------------------------------------------ +// +// 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 GameConfig.Battle +{ + +public sealed partial class SkillAttrDamageData : Bright.Config.BeanBase +{ + public SkillAttrDamageData(JSONNode _json) + { + { if(!_json["MagicType"].IsNumber) { throw new SerializationException(); } MagicType = (Battle.SkillMagicType)_json["MagicType"].AsInt; } + { if(!_json["AttrType"].IsNumber) { throw new SerializationException(); } AttrType = (Battle.SkillAttrDamageType)_json["AttrType"].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"]; } + { if(!_json["MaxLimit"].IsNumber) { throw new SerializationException(); } MaxLimit = _json["MaxLimit"]; } + PostInit(); + } + + public SkillAttrDamageData(Battle.SkillMagicType MagicType, Battle.SkillAttrDamageType AttrType, float Param1, float Param2, float Param3, float MaxLimit ) + { + this.MagicType = MagicType; + this.AttrType = AttrType; + this.Param1 = Param1; + this.Param2 = Param2; + this.Param3 = Param3; + this.MaxLimit = MaxLimit; + PostInit(); + } + + public static SkillAttrDamageData DeserializeSkillAttrDamageData(JSONNode _json) + { + return new Battle.SkillAttrDamageData(_json); + } + + public Battle.SkillMagicType MagicType { get; private set; } + public Battle.SkillAttrDamageType AttrType { get; private set; } + public float Param1 { get; private set; } + public float Param2 { get; private set; } + public float Param3 { get; private set; } + public float MaxLimit { get; private set; } + + public const int __ID__ = -94519547; + public override int GetTypeId() => __ID__; + + public void Resolve(Dictionary _tables) + { + PostResolve(); + } + + public void TranslateText(System.Func translator) + { + } + + public override string ToString() + { + return "{ " + + "MagicType:" + MagicType + "," + + "AttrType:" + AttrType + "," + + "Param1:" + Param1 + "," + + "Param2:" + Param2 + "," + + "Param3:" + Param3 + "," + + "MaxLimit:" + MaxLimit + "," + + "}"; + } + + partial void PostInit(); + partial void PostResolve(); +} +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillAttrDamageData.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillAttrDamageData.cs.meta new file mode 100644 index 00000000..80d66e92 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillAttrDamageData.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 485330d35ed83074e98aee4f9afebff7 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillAttrDamageType.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillAttrDamageType.cs new file mode 100644 index 00000000..13d58d51 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillAttrDamageType.cs @@ -0,0 +1,40 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + + +namespace GameConfig.Battle +{ + public enum SkillAttrDamageType + { + /// + /// 无数值 + /// + ATTR_TYPE_NONE = 0, + /// + /// 按释放者的伤害类型*X%+固定值计算,目标有防御计算 + /// + ATTR_TYPE_DMG_WEAPON = 1, + /// + /// 按释放者的伤害类型*X%+固定值计算(无视目标的防御) + /// + ATTR_TYPE_DMG_NO_DEFEND = 2, + /// + /// 按受击者的气血上限*X%+固定值计算(无视目标的防御) + /// + ATTR_TYPE_DMG_TARGET_HP_NO_DEFEND = 3, + /// + /// 按释放者的攻击类型*X%+固定值计算,恢复当前生命 + /// + ATTR_TYPE_HP_AS_ATK = 4, + /// + /// 按受击者的HP上限*X%+固定值计算,恢复当前生命 + /// + ATTR_TYPE_HP_RATIO = 5, + } + +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillAttrDamageType.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillAttrDamageType.cs.meta new file mode 100644 index 00000000..288ffd25 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillAttrDamageType.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: a875b3c697d164841b02d808b103a384 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillBaseConfig.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillBaseConfig.cs new file mode 100644 index 00000000..1c29bb38 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillBaseConfig.cs @@ -0,0 +1,132 @@ +//------------------------------------------------------------------------------ +// +// 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 GameConfig.Battle +{ + +public sealed partial class SkillBaseConfig : Bright.Config.BeanBase +{ + public SkillBaseConfig(JSONNode _json) + { + { if(!_json["id"].IsNumber) { throw new SerializationException(); } Id = _json["id"]; } + { if(!_json["name"].IsString) { throw new SerializationException(); } Name = _json["name"]; } + { if(!_json["SkillDispID"].IsNumber) { throw new SerializationException(); } SkillDispID = _json["SkillDispID"]; } + { if(!_json["SkillType"].IsNumber) { throw new SerializationException(); } SkillType = _json["SkillType"]; } + { if(!_json["desc"].IsString) { throw new SerializationException(); } Desc = _json["desc"]; } + { if(!_json["CostMP"].IsNumber) { throw new SerializationException(); } CostMP = _json["CostMP"]; } + { if(!_json["GCDID"].IsNumber) { throw new SerializationException(); } GCDID = _json["GCDID"]; } + { if(!_json["SkillCD"].IsNumber) { throw new SerializationException(); } SkillCD = _json["SkillCD"]; } + { if(!_json["IsRepeatTrigger"].IsBoolean) { throw new SerializationException(); } IsRepeatTrigger = _json["IsRepeatTrigger"]; } + { var __json0 = _json["BuffID"]; if(!__json0.IsArray) { throw new SerializationException(); } BuffID = new System.Collections.Generic.List(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { int __v0; { if(!__e0.IsNumber) { throw new SerializationException(); } __v0 = __e0; } BuffID.Add(__v0); } } + { var __json0 = _json["AttrDamageData"]; if(!__json0.IsArray) { throw new SerializationException(); } AttrDamageData = new System.Collections.Generic.List(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { Battle.SkillAttrDamageData __v0; { if(!__e0.IsObject) { throw new SerializationException(); } __v0 = Battle.SkillAttrDamageData.DeserializeSkillAttrDamageData(__e0); } AttrDamageData.Add(__v0); } } + PostInit(); + } + + public SkillBaseConfig(int id, string name, int SkillDispID, int SkillType, string desc, int CostMP, int GCDID, float SkillCD, bool IsRepeatTrigger, System.Collections.Generic.List BuffID, System.Collections.Generic.List AttrDamageData ) + { + this.Id = id; + this.Name = name; + this.SkillDispID = SkillDispID; + this.SkillType = SkillType; + this.Desc = desc; + this.CostMP = CostMP; + this.GCDID = GCDID; + this.SkillCD = SkillCD; + this.IsRepeatTrigger = IsRepeatTrigger; + this.BuffID = BuffID; + this.AttrDamageData = AttrDamageData; + PostInit(); + } + + public static SkillBaseConfig DeserializeSkillBaseConfig(JSONNode _json) + { + return new Battle.SkillBaseConfig(_json); + } + + /// + /// 技能ID + /// + public int Id { get; private set; } + /// + /// 名字 + /// + public string Name { get; private set; } + /// + /// 表现ID + /// + public int SkillDispID { get; private set; } + /// + /// 技能类型SkillType + /// + public int SkillType { get; private set; } + /// + /// 描述 + /// + public string Desc { get; private set; } + /// + /// 消耗MP + /// + public int CostMP { get; private set; } + /// + /// 所属公CD组ID + /// + public int GCDID { get; private set; } + /// + /// 技能CD + /// + public float SkillCD { get; private set; } + /// + /// 是否重复触发 + /// + public bool IsRepeatTrigger { get; private set; } + /// + /// BuffIDList + /// + public System.Collections.Generic.List BuffID { get; private set; } + public System.Collections.Generic.List AttrDamageData { get; private set; } + + public const int __ID__ = 2067672430; + public override int GetTypeId() => __ID__; + + public void Resolve(Dictionary _tables) + { + foreach(var _e in AttrDamageData) { _e?.Resolve(_tables); } + PostResolve(); + } + + public void TranslateText(System.Func translator) + { + foreach(var _e in AttrDamageData) { _e?.TranslateText(translator); } + } + + public override string ToString() + { + return "{ " + + "Id:" + Id + "," + + "Name:" + Name + "," + + "SkillDispID:" + SkillDispID + "," + + "SkillType:" + SkillType + "," + + "Desc:" + Desc + "," + + "CostMP:" + CostMP + "," + + "GCDID:" + GCDID + "," + + "SkillCD:" + SkillCD + "," + + "IsRepeatTrigger:" + IsRepeatTrigger + "," + + "BuffID:" + Bright.Common.StringUtil.CollectionToString(BuffID) + "," + + "AttrDamageData:" + Bright.Common.StringUtil.CollectionToString(AttrDamageData) + "," + + "}"; + } + + partial void PostInit(); + partial void PostResolve(); +} +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillBaseConfig.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillBaseConfig.cs.meta new file mode 100644 index 00000000..e1d678ad --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillBaseConfig.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: b651cf87b4372cf4a8894a9421a6dcff +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillMagicType.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillMagicType.cs new file mode 100644 index 00000000..54088689 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillMagicType.cs @@ -0,0 +1,28 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + + +namespace GameConfig.Battle +{ + public enum SkillMagicType + { + /// + /// 无类型 + /// + SKILL_TYPE_NONE = 0, + /// + /// 物理伤害属性 + /// + SKILL_TYPE_DMG_PHY = 1, + /// + /// 魔法伤害属性 + /// + SKILL_TYPE_DMG_MAGIC = 2, + } + +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillMagicType.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillMagicType.cs.meta new file mode 100644 index 00000000..f5981cee --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/SkillMagicType.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 050deaa6f717a36428b057b5c1f889b2 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbBuff.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbBuff.cs new file mode 100644 index 00000000..feac2bba --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbBuff.cs @@ -0,0 +1,65 @@ +//------------------------------------------------------------------------------ +// +// 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 GameConfig.Battle +{ + +public sealed partial class TbBuff +{ + private readonly Dictionary _dataMap; + private readonly List _dataList; + + public TbBuff(JSONNode _json) + { + _dataMap = new Dictionary(); + _dataList = new List(); + + foreach(JSONNode _row in _json.Children) + { + var _v = Battle.BuffConfig.DeserializeBuffConfig(_row); + _dataList.Add(_v); + _dataMap.Add(_v.BuffID, _v); + } + PostInit(); + } + + public Dictionary DataMap => _dataMap; + public List DataList => _dataList; + + public Battle.BuffConfig GetOrDefault(int key) => _dataMap.TryGetValue(key, out var v) ? v : null; + public Battle.BuffConfig Get(int key) => _dataMap[key]; + public Battle.BuffConfig this[int key] => _dataMap[key]; + + public void Resolve(Dictionary _tables) + { + foreach(var v in _dataList) + { + v.Resolve(_tables); + } + PostResolve(); + } + + public void TranslateText(System.Func translator) + { + foreach(var v in _dataList) + { + v.TranslateText(translator); + } + } + + + partial void PostInit(); + partial void PostResolve(); +} + +} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbBuff.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbBuff.cs.meta new file mode 100644 index 00000000..2f33266b --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbBuff.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 4bae3a42b1e627f44b53f42fa8835064 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbBuffAttr.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbBuffAttr.cs new file mode 100644 index 00000000..7045f56b --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbBuffAttr.cs @@ -0,0 +1,65 @@ +//------------------------------------------------------------------------------ +// +// 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 GameConfig.Battle +{ + +public sealed partial class TbBuffAttr +{ + private readonly Dictionary _dataMap; + private readonly List _dataList; + + public TbBuffAttr(JSONNode _json) + { + _dataMap = new Dictionary(); + _dataList = new List(); + + foreach(JSONNode _row in _json.Children) + { + var _v = Battle.BuffAttrConfig.DeserializeBuffAttrConfig(_row); + _dataList.Add(_v); + _dataMap.Add(_v.BuffID, _v); + } + PostInit(); + } + + public Dictionary DataMap => _dataMap; + public List DataList => _dataList; + + public Battle.BuffAttrConfig GetOrDefault(int key) => _dataMap.TryGetValue(key, out var v) ? v : null; + public Battle.BuffAttrConfig Get(int key) => _dataMap[key]; + public Battle.BuffAttrConfig this[int key] => _dataMap[key]; + + public void Resolve(Dictionary _tables) + { + foreach(var v in _dataList) + { + v.Resolve(_tables); + } + PostResolve(); + } + + public void TranslateText(System.Func translator) + { + foreach(var v in _dataList) + { + v.TranslateText(translator); + } + } + + + partial void PostInit(); + partial void PostResolve(); +} + +} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbBuffAttr.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbBuffAttr.cs.meta new file mode 100644 index 00000000..e7efa5c4 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbBuffAttr.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 67c85d7e042f25f4b8728ea5d0260af4 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbSkill.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbSkill.cs new file mode 100644 index 00000000..5b40add9 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbSkill.cs @@ -0,0 +1,65 @@ +//------------------------------------------------------------------------------ +// +// 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 GameConfig.Battle +{ + +public sealed partial class TbSkill +{ + private readonly Dictionary _dataMap; + private readonly List _dataList; + + public TbSkill(JSONNode _json) + { + _dataMap = new Dictionary(); + _dataList = new List(); + + foreach(JSONNode _row in _json.Children) + { + var _v = Battle.SkillBaseConfig.DeserializeSkillBaseConfig(_row); + _dataList.Add(_v); + _dataMap.Add(_v.Id, _v); + } + PostInit(); + } + + public Dictionary DataMap => _dataMap; + public List DataList => _dataList; + + public Battle.SkillBaseConfig GetOrDefault(int key) => _dataMap.TryGetValue(key, out var v) ? v : null; + public Battle.SkillBaseConfig Get(int key) => _dataMap[key]; + public Battle.SkillBaseConfig this[int key] => _dataMap[key]; + + public void Resolve(Dictionary _tables) + { + foreach(var v in _dataList) + { + v.Resolve(_tables); + } + PostResolve(); + } + + public void TranslateText(System.Func translator) + { + foreach(var v in _dataList) + { + v.TranslateText(translator); + } + } + + + partial void PostInit(); + partial void PostResolve(); +} + +} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbSkill.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbSkill.cs.meta new file mode 100644 index 00000000..9ce438e0 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Battle/TbSkill.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 4225d28df041ab84e93ed201b8c52f3e +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Tables.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/Tables.cs new file mode 100644 index 00000000..4e2402f9 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Tables.cs @@ -0,0 +1,54 @@ +//------------------------------------------------------------------------------ +// +// 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 SimpleJSON; + + +namespace GameConfig +{ + +public sealed partial class Tables +{ + public item.TbItem TbItem {get; } + public Battle.TbSkill TbSkill {get; } + public Battle.TbBuff TbBuff {get; } + public Battle.TbBuffAttr TbBuffAttr {get; } + + public Tables(System.Func loader) + { + var tables = new System.Collections.Generic.Dictionary(); + TbItem = new item.TbItem(loader("item_tbitem")); + tables.Add("item.TbItem", TbItem); + TbSkill = new Battle.TbSkill(loader("battle_tbskill")); + tables.Add("Battle.TbSkill", TbSkill); + TbBuff = new Battle.TbBuff(loader("battle_tbbuff")); + tables.Add("Battle.TbBuff", TbBuff); + TbBuffAttr = new Battle.TbBuffAttr(loader("battle_tbbuffattr")); + tables.Add("Battle.TbBuffAttr", TbBuffAttr); + PostInit(); + + TbItem.Resolve(tables); + TbSkill.Resolve(tables); + TbBuff.Resolve(tables); + TbBuffAttr.Resolve(tables); + PostResolve(); + } + + public void TranslateText(System.Func translator) + { + TbItem.TranslateText(translator); + TbSkill.TranslateText(translator); + TbBuff.TranslateText(translator); + TbBuffAttr.TranslateText(translator); + } + + partial void PostInit(); + partial void PostResolve(); +} + +} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/Tables.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/Tables.cs.meta new file mode 100644 index 00000000..6de08c5d --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/Tables.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 45e65de224e02f04db3ee7af36494bb9 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/item.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/item.meta new file mode 100644 index 00000000..a91465e9 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/item.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 92dacb95febd2204ca6721a0794739ba +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/item/EQuality.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/item/EQuality.cs new file mode 100644 index 00000000..0b92406c --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/item/EQuality.cs @@ -0,0 +1,32 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + + +namespace GameConfig.item +{ + public enum EQuality + { + /// + /// 最差品质 + /// + WHITE = 1, + /// + /// 蓝色的 + /// + BLUE = 2, + /// + /// 紫色的 + /// + PURPLE = 3, + /// + /// 最高品质 + /// + RED = 4, + } + +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/item/EQuality.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/item/EQuality.cs.meta new file mode 100644 index 00000000..99340901 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/item/EQuality.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 30c573667ec26fd478ae418601d60abf +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/item/Item.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/item/Item.cs new file mode 100644 index 00000000..c4e0d2c4 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/item/Item.cs @@ -0,0 +1,138 @@ +//------------------------------------------------------------------------------ +// +// 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 GameConfig.item +{ + +public sealed partial class Item : Bright.Config.BeanBase +{ + public Item(JSONNode _json) + { + { if(!_json["id"].IsNumber) { throw new SerializationException(); } Id = _json["id"]; } + { if(!_json["name"].IsString) { throw new SerializationException(); } Name = _json["name"]; } + { if(!_json["desc"].IsString) { throw new SerializationException(); } Desc = _json["desc"]; } + { if(!_json["price"].IsNumber) { throw new SerializationException(); } Price = _json["price"]; } + { if(!_json["upgrade_to_item_id"].IsNumber) { throw new SerializationException(); } UpgradeToItemId = _json["upgrade_to_item_id"]; } + { var _j = _json["expire_time"]; if (_j.Tag != JSONNodeType.None && _j.Tag != JSONNodeType.NullValue) { { if(!_j.IsNumber) { throw new SerializationException(); } ExpireTime = _j; } } else { ExpireTime = null; } } + { if(!_json["batch_useable"].IsBoolean) { throw new SerializationException(); } BatchUseable = _json["batch_useable"]; } + { if(!_json["quality"].IsNumber) { throw new SerializationException(); } Quality = (item.EQuality)_json["quality"].AsInt; } + { if(!_json["exchange_stream"].IsObject) { throw new SerializationException(); } ExchangeStream = item.ItemExchange.DeserializeItemExchange(_json["exchange_stream"]); } + { var __json0 = _json["exchange_list"]; if(!__json0.IsArray) { throw new SerializationException(); } ExchangeList = new System.Collections.Generic.List(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { item.ItemExchange __v0; { if(!__e0.IsObject) { throw new SerializationException(); } __v0 = item.ItemExchange.DeserializeItemExchange(__e0); } ExchangeList.Add(__v0); } } + { if(!_json["exchange_column"].IsObject) { throw new SerializationException(); } ExchangeColumn = item.ItemExchange.DeserializeItemExchange(_json["exchange_column"]); } + PostInit(); + } + + public Item(int id, string name, string desc, int price, int upgrade_to_item_id, int? expire_time, bool batch_useable, item.EQuality quality, item.ItemExchange exchange_stream, System.Collections.Generic.List exchange_list, item.ItemExchange exchange_column ) + { + this.Id = id; + this.Name = name; + this.Desc = desc; + this.Price = price; + this.UpgradeToItemId = upgrade_to_item_id; + this.ExpireTime = expire_time; + this.BatchUseable = batch_useable; + this.Quality = quality; + this.ExchangeStream = exchange_stream; + this.ExchangeList = exchange_list; + this.ExchangeColumn = exchange_column; + PostInit(); + } + + public static Item DeserializeItem(JSONNode _json) + { + return new item.Item(_json); + } + + /// + /// 这是id + /// + public int Id { get; private set; } + /// + /// 名字 + /// + public string Name { get; private set; } + /// + /// 描述 + /// + public string Desc { get; private set; } + /// + /// 价格 + /// + public int Price { get; private set; } + /// + /// 引用当前表 + /// + public int UpgradeToItemId { get; private set; } + public item.Item UpgradeToItemId_Ref { get; private set; } + /// + /// 过期时间 + /// + public int? ExpireTime { get; private set; } + /// + /// 能否批量使用 + /// + public bool BatchUseable { get; private set; } + /// + /// 品质 + /// + public item.EQuality Quality { get; private set; } + /// + /// 道具兑换配置 + /// + public item.ItemExchange ExchangeStream { get; private set; } + public System.Collections.Generic.List ExchangeList { get; private set; } + /// + /// 道具兑换配置 + /// + public item.ItemExchange ExchangeColumn { get; private set; } + + public const int __ID__ = 2107285806; + public override int GetTypeId() => __ID__; + + public void Resolve(Dictionary _tables) + { + this.UpgradeToItemId_Ref = (_tables["item.TbItem"] as item.TbItem).GetOrDefault(UpgradeToItemId); + ExchangeStream?.Resolve(_tables); + foreach(var _e in ExchangeList) { _e?.Resolve(_tables); } + ExchangeColumn?.Resolve(_tables); + PostResolve(); + } + + public void TranslateText(System.Func translator) + { + ExchangeStream?.TranslateText(translator); + foreach(var _e in ExchangeList) { _e?.TranslateText(translator); } + ExchangeColumn?.TranslateText(translator); + } + + public override string ToString() + { + return "{ " + + "Id:" + Id + "," + + "Name:" + Name + "," + + "Desc:" + Desc + "," + + "Price:" + Price + "," + + "UpgradeToItemId:" + UpgradeToItemId + "," + + "ExpireTime:" + ExpireTime + "," + + "BatchUseable:" + BatchUseable + "," + + "Quality:" + Quality + "," + + "ExchangeStream:" + ExchangeStream + "," + + "ExchangeList:" + Bright.Common.StringUtil.CollectionToString(ExchangeList) + "," + + "ExchangeColumn:" + ExchangeColumn + "," + + "}"; + } + + partial void PostInit(); + partial void PostResolve(); +} +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/item/Item.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/item/Item.cs.meta new file mode 100644 index 00000000..4a85d5c8 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/item/Item.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 3e65d3e4aa74f27438c746308c434ed9 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/item/ItemExchange.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/item/ItemExchange.cs new file mode 100644 index 00000000..3f7c7a58 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/item/ItemExchange.cs @@ -0,0 +1,70 @@ +//------------------------------------------------------------------------------ +// +// 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 GameConfig.item +{ + +public sealed partial class ItemExchange : Bright.Config.BeanBase +{ + public ItemExchange(JSONNode _json) + { + { if(!_json["id"].IsNumber) { throw new SerializationException(); } Id = _json["id"]; } + { if(!_json["num"].IsNumber) { throw new SerializationException(); } Num = _json["num"]; } + PostInit(); + } + + public ItemExchange(int id, int num ) + { + this.Id = id; + this.Num = num; + PostInit(); + } + + public static ItemExchange DeserializeItemExchange(JSONNode _json) + { + return new item.ItemExchange(_json); + } + + /// + /// 道具id + /// + public int Id { get; private set; } + /// + /// 道具数量 + /// + public int Num { get; private set; } + + public const int __ID__ = 1814660465; + public override int GetTypeId() => __ID__; + + public void Resolve(Dictionary _tables) + { + PostResolve(); + } + + public void TranslateText(System.Func translator) + { + } + + public override string ToString() + { + return "{ " + + "Id:" + Id + "," + + "Num:" + Num + "," + + "}"; + } + + partial void PostInit(); + partial void PostResolve(); +} +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/item/ItemExchange.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/item/ItemExchange.cs.meta new file mode 100644 index 00000000..c8e62931 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/item/ItemExchange.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 9a752eb48ae7a124fba2dba3d3ca2c4e +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/item/TbItem.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/item/TbItem.cs new file mode 100644 index 00000000..0cf01731 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/item/TbItem.cs @@ -0,0 +1,65 @@ +//------------------------------------------------------------------------------ +// +// 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 GameConfig.item +{ + +public sealed partial class TbItem +{ + private readonly Dictionary _dataMap; + private readonly List _dataList; + + public TbItem(JSONNode _json) + { + _dataMap = new Dictionary(); + _dataList = new List(); + + foreach(JSONNode _row in _json.Children) + { + var _v = item.Item.DeserializeItem(_row); + _dataList.Add(_v); + _dataMap.Add(_v.Id, _v); + } + PostInit(); + } + + public Dictionary DataMap => _dataMap; + public List DataList => _dataList; + + public item.Item GetOrDefault(int key) => _dataMap.TryGetValue(key, out var v) ? v : null; + public item.Item Get(int key) => _dataMap[key]; + public item.Item this[int key] => _dataMap[key]; + + public void Resolve(Dictionary _tables) + { + foreach(var v in _dataList) + { + v.Resolve(_tables); + } + PostResolve(); + } + + public void TranslateText(System.Func translator) + { + foreach(var v in _dataList) + { + v.TranslateText(translator); + } + } + + + partial void PostInit(); + partial void PostResolve(); +} + +} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/item/TbItem.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/item/TbItem.cs.meta new file mode 100644 index 00000000..97ac565f --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/item/TbItem.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 2ab4162ad0234444ea02f248b5c325c9 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/test.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/test.meta new file mode 100644 index 00000000..9cd66779 --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/test.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 1fb403cf09ac38a49aea0b887a068cba +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/test/AccessFlag.cs b/Assets/GameScripts/HotFix/GameProto/GameConfig/test/AccessFlag.cs new file mode 100644 index 00000000..800b278e --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/test/AccessFlag.cs @@ -0,0 +1,25 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + + +namespace GameConfig.test +{ + [System.Flags] + public enum AccessFlag + { + WRITE = 1, + READ = 2, + TRUNCATE = 4, + NEW = 8, + /// + /// 位标记使用示例 + /// + READ_WRITE = WRITE|READ, + } + +} diff --git a/Assets/GameScripts/HotFix/GameProto/GameConfig/test/AccessFlag.cs.meta b/Assets/GameScripts/HotFix/GameProto/GameConfig/test/AccessFlag.cs.meta new file mode 100644 index 00000000..15f9fb4d --- /dev/null +++ b/Assets/GameScripts/HotFix/GameProto/GameConfig/test/AccessFlag.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 0fa3d642fac8be9429d88fe4823320e0 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/GameScripts/HotFix/GameProto/GameProto.asmdef b/Assets/GameScripts/HotFix/GameProto/GameProto.asmdef index 709a41c1..6bd487fc 100644 --- a/Assets/GameScripts/HotFix/GameProto/GameProto.asmdef +++ b/Assets/GameScripts/HotFix/GameProto/GameProto.asmdef @@ -3,6 +3,7 @@ "rootNamespace": "", "references": [ "GUID:b48be955427611241bcb6f2a07949c5b", + "GUID:08c3762f54316454ca6b6fbcb22b40e5", "GUID:aa06d4cc755c979489c256c1bcca1dfb" ], "includePlatforms": [],