diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo.meta deleted file mode 100644 index 18cb954b..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: ab10a5a730054c5aaa942164c750abfb -timeCreated: 1689576189 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core.meta deleted file mode 100644 index 7236d85e..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 94212c40840344b5bd6ba4fc82097d47 -timeCreated: 1689576337 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic.meta deleted file mode 100644 index 9966eb40..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 78e93a657ea64d5d97000e8b6cc83ffc -timeCreated: 1689576342 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Attr.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Attr.meta deleted file mode 100644 index 10d27cac..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Attr.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 3212280593954784b888cf6e9fa088a8 -timeCreated: 1689584199 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Attr/ActorData.cs b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Attr/ActorData.cs deleted file mode 100644 index 3b56d018..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Attr/ActorData.cs +++ /dev/null @@ -1,11 +0,0 @@ -using TEngine; - -namespace GameLogic.BattleDemo -{ - /// - /// Actor属性数据管理。 - /// - public class ActorData : EntityLogicComponent - { - } -} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Attr/ActorData.cs.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Attr/ActorData.cs.meta deleted file mode 100644 index 74e9f36f..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Attr/ActorData.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: a344b822c96449a29d78fb64b02c762d -timeCreated: 1689584206 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Buff.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Buff.meta deleted file mode 100644 index 9a828f71..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Buff.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: cc314cd9682f4c1d8a870e2b4c6a5c88 -timeCreated: 1689584122 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Buff/BuffComponent.cs b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Buff/BuffComponent.cs deleted file mode 100644 index 23879881..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Buff/BuffComponent.cs +++ /dev/null @@ -1,86 +0,0 @@ -using System.Collections.Generic; -using System.Linq; -using TEngine; - -namespace GameLogic.BattleDemo -{ - /// - /// 实体类的Buff管理。 - /// - public class BuffComponent:EntityLogicComponent - { - private readonly Dictionary _allBuff = new Dictionary(); - private readonly List _listBuff = new List(); - - - public override void Dispose() - { - foreach (var bufferItem in _listBuff) - { - BufferItem.Release(bufferItem); - } - _listBuff.Clear(); - _allBuff.Clear(); - base.Dispose(); - } - - /// - /// 增加Buff。 - /// - /// BuffId。 - /// 施法者。 - /// 增加层数。 - /// 技能Id。 - /// - public bool AddBuff(int buffId, EntityLogic caster, int addStackNum = 1, uint skillId = 0) - { - BufferItem bufferItem = BufferItem.Alloc(buffId); - if (bufferItem == null) - { - return false; - } - RefreshBuffAttr(); - UpdateBuffState(); - _allBuff.Add(buffId, bufferItem); - _listBuff.Add(bufferItem); - return true; - } - - /// - /// 移除Buff。 - /// - /// BuffID。 - /// 移除施放来源。 - public void RmvBuff(int buffID, EntityLogic caster) - { - if (_allBuff.TryGetValue(buffID, out BufferItem buffItem)) - { - RemoveBuffFromList(buffItem); - RefreshBuffAttr(); - UpdateBuffState(); - } - } - - private void RemoveBuffFromList(BufferItem buffItem) - { - Log.Info("remove buff: {0}", buffItem.BuffID); - BufferItem.Release(buffItem); - _allBuff.Remove(buffItem.BuffID); - _listBuff.Remove(buffItem); - } - - /// - /// 刷新Buff带来的属性。 - /// - private void RefreshBuffAttr() - { - } - - /// - /// 刷新Buff改变的状态。 - /// - private void UpdateBuffState() - { - } - } -} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Buff/BuffComponent.cs.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Buff/BuffComponent.cs.meta deleted file mode 100644 index 87408c77..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Buff/BuffComponent.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 29088ba5001247628aefb072c6d82705 -timeCreated: 1689582372 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Buff/BufferItem.cs b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Buff/BufferItem.cs deleted file mode 100644 index 5b1c2fab..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Buff/BufferItem.cs +++ /dev/null @@ -1,62 +0,0 @@ -using GameConfig.Battle; -using TEngine; - -namespace GameLogic.BattleDemo -{ - /// - /// Buff实例。 - /// - public class BufferItem:IMemory - { - /// - /// BuffId。 - /// - public int BuffID => BuffConfig?.BuffID ?? 0; - - /// - /// BUff配置表。 - /// - public BuffConfig BuffConfig { private set; get; } - - /// - /// 清理内存。 - /// - public void Clear() - { - BuffConfig = null; - } - - /// - /// 生成Buff实例。 - /// - /// buffId。 - /// Buff实例。 - public static BufferItem Alloc(int buffId) - { - Log.Debug($"Alloc buffItem buffId:{buffId}"); - BuffConfig buffConfig = ConfigLoader.Instance.Tables.TbBuff.Get(buffId); - if (buffConfig == null) - { - Log.Warning($"Alloc buffItem Failed ! buffId:{buffId}"); - return null; - } - - BufferItem ret = MemoryPool.Acquire(); - ret.BuffConfig = buffConfig; - return ret; - } - - /// - /// 释放Buff实例。 - /// - /// - public static void Release(BufferItem bufferItem) - { - if (bufferItem == null) - { - return; - } - MemoryPool.Release(bufferItem); - } - } -} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Buff/BufferItem.cs.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Buff/BufferItem.cs.meta deleted file mode 100644 index 153ef7bb..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Buff/BufferItem.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 8915b9545484419eb2642a69d4056daf -timeCreated: 1689584322 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityCreateData.cs b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityCreateData.cs deleted file mode 100644 index 02d711f6..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityCreateData.cs +++ /dev/null @@ -1,39 +0,0 @@ -using TEngine; -using UnityEngine; - -namespace GameLogic.BattleDemo -{ - /// - /// 实体创建预数据。 - /// - public class EntityCreateData:IMemory - { - public ActorEntityType actorEntityType; - - public bool HasBornPos = false; - - public Vector3 BornPos; - - public Vector3 BornForward; - - /// - /// 设置出生点。 - /// - /// - /// - public void SetBornPos(Vector3 bornPos, Vector3 forward) - { - HasBornPos = true; - BornPos = bornPos; - BornForward = forward; - } - - public void Clear() - { - actorEntityType = ActorEntityType.None; - HasBornPos = false; - BornPos = Vector3.zero; - BornForward = Vector3.zero; - } - } -} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityCreateData.cs.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityCreateData.cs.meta deleted file mode 100644 index 0965d4b3..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityCreateData.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 4ba847c6eb944645a4b693f1a432d933 -timeCreated: 1689583498 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityLogic.cs b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityLogic.cs deleted file mode 100644 index 3e717007..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityLogic.cs +++ /dev/null @@ -1,65 +0,0 @@ -using TEngine; - -namespace GameLogic.BattleDemo -{ - /// - /// 逻辑层实体。 - /// - public abstract class EntityLogic : Entity - { - /// - /// 逻辑层实体类型。 - /// - /// - public abstract ActorEntityType GetActorEntityType(); - - /// - /// 是否是战斗起始的Actor。 - /// ,比如双方参与战斗的玩家,或者技能编辑器里的Caster。 - /// - public bool IsStartActor; - - public EntityCreateData CreateData { private set; get; } - - public virtual string GetActorName() - { - return string.Empty; - } - - #region 缓存常用组件 - public ActorData ActorData { protected set; get; } - - public BuffComponent BuffComponent { protected set; get; } - public SkillCasterComponent SkillCaster { protected set; get; } - #endregion - - #region 生命周期 - - internal bool LogicCreate(EntityCreateData entityCreateData) - { - CreateData = entityCreateData; - OnLogicCreate(); - return true; - } - - protected virtual void OnLogicCreate() - { - - } - - internal void LogicDestroy() - { - OnLogicDestroy(); - if (CreateData != null) - { - MemoryPool.Release(CreateData); - } - } - - protected virtual void OnLogicDestroy() - { - - } - #endregion - } -} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityLogic.cs.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityLogic.cs.meta deleted file mode 100644 index c118c2b5..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityLogic.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: e7b01c5b166445d680dc411dfbe5c781 -timeCreated: 1689576203 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityLogicComponent.cs b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityLogicComponent.cs deleted file mode 100644 index f2c53484..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityLogicComponent.cs +++ /dev/null @@ -1,12 +0,0 @@ -using TEngine; - -namespace GameLogic.BattleDemo -{ - /// - /// 逻辑层组件实体。 - /// - public abstract class EntityLogicComponent: Entity - { - public EntityLogic Owner => (EntityLogic)Parent; - } -} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityLogicComponent.cs.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityLogicComponent.cs.meta deleted file mode 100644 index 013b5a33..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityLogicComponent.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 92574294d8144f218f323f63f72a8374 -timeCreated: 1689585864 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityLogicMgr.cs b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityLogicMgr.cs deleted file mode 100644 index 10c1658c..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityLogicMgr.cs +++ /dev/null @@ -1,143 +0,0 @@ -using System; -using System.Collections.Generic; -using TEngine; - -namespace GameLogic.BattleDemo -{ - /// - /// 实体类型。 - /// - public enum ActorEntityType - { - None, - Player, - Monster, - Pet, - Npc, - } - - /// - /// 逻辑层实体管理器。 - /// - public class EntityLogicMgr - { - private static readonly Dictionary EntityLogicPool = new Dictionary(); - private static readonly List ListEntityLogics = new List(); - - public static event Action OnEntityCreate; - public static event Action OnEntityDestroy; - - public static List GetAllActor(ref List temp) - { - if (temp == null) - { - temp = new List(); - } - temp.AddRange(ListEntityLogics); - return temp; - } - - public static List GetTypeActor(ref List temp,ActorEntityType type) - { - if (temp == null) - { - temp = new List(); - } - - foreach (var actor in ListEntityLogics) - { - if (actor.GetActorEntityType() == type) - { - temp.Add(actor); - } - } - return temp; - } - - public static EntityLogic CreateEntityLogic(EntityCreateData entityCreateData, bool isStartActor = false) - { - if (entityCreateData == null) - { - Log.Error("create actor failed, create data is null"); - return null; - } - var actor = CreateActorEntityObject(entityCreateData.actorEntityType); - if (actor == null) - { - Log.Error("create actor failed, create data is {0}", entityCreateData); - return null; - } - - actor.IsStartActor = isStartActor; - if (!actor.LogicCreate(entityCreateData)) - { - DestroyActor(actor); - return null; - } - - if (OnEntityCreate != null) - { - OnEntityCreate(actor); - } - - Log.Debug("entityLogic created: {0}", actor.GetActorName()); - return actor; - } - - private static EntityLogic CreateActorEntityObject(ActorEntityType actorType) - { - EntityLogic entityLogic = null; - - switch (actorType) - { - case ActorEntityType.Player: - { - entityLogic = Entity.Create(GameApp.Instance.Scene); - break; - } - default: - { - Log.Error("unknown actor type:{0}", actorType); - break; - } - } - - if (entityLogic != null) - { - EntityLogicPool.Add(entityLogic.RuntimeId, entityLogic); - ListEntityLogics.Add(entityLogic); - } - return entityLogic; - } - - - public static bool DestroyActor(long runtimeId) - { - EntityLogicPool.TryGetValue(runtimeId, out EntityLogic entityLogic); - if (entityLogic != null) - { - return DestroyActor(entityLogic); - } - return false; - } - - public static bool DestroyActor(EntityLogic entityLogic) - { - Log.Debug("on destroy entityLogic {0}", entityLogic.RuntimeId); - - - var runtimeId = entityLogic.RuntimeId; - Log.Assert(EntityLogicPool.ContainsKey(runtimeId)); - - if (OnEntityDestroy != null) - { - OnEntityDestroy(entityLogic); - } - - entityLogic.LogicDestroy(); - EntityLogicPool.Remove(runtimeId); - ListEntityLogics.Remove(entityLogic); - return true; - } - } -} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityLogicMgr.cs.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityLogicMgr.cs.meta deleted file mode 100644 index 58b70cc7..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/EntityLogicMgr.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 513b12007c8f408698d12aee22fc44db -timeCreated: 1689579220 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/PlayerEntity.cs b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/PlayerEntity.cs deleted file mode 100644 index 9568e688..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/PlayerEntity.cs +++ /dev/null @@ -1,18 +0,0 @@ -namespace GameLogic.BattleDemo -{ - public class PlayerEntity : EntityLogic - { - public override ActorEntityType GetActorEntityType() - { - return ActorEntityType.Player; - } - - protected override void OnLogicCreate() - { - base.OnLogicCreate(); - ActorData = AddComponent(); - BuffComponent = AddComponent(); - SkillCaster = AddComponent(); - } - } -} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/PlayerEntity.cs.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/PlayerEntity.cs.meta deleted file mode 100644 index 1fee6445..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/PlayerEntity.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 9939517fe9f04f0d9c0c544fbdd43564 -timeCreated: 1689576650 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill.meta deleted file mode 100644 index 75d3e45a..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 8d126355d2da45c8899a7a4fff5d376c -timeCreated: 1689584135 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillCasterComponent.cs b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillCasterComponent.cs deleted file mode 100644 index a3bf7540..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillCasterComponent.cs +++ /dev/null @@ -1,35 +0,0 @@ -using TEngine; - -namespace GameLogic.BattleDemo -{ - /// - /// 技能释放组件。 - /// - public class SkillCasterComponent:EntityLogicComponent - { - - /// - /// 播放技能。 - /// - /// 技能Id。 - /// 目标。 - /// 是否检测CD。 - /// 是否强制释放。 - /// 是否播放成功。 - internal void PlaySkill(int skillId, EntityLogic target = null, bool forceCaster = false, bool checkCd = true) - { - Log.Assert(skillId > 0, $"ActorName: {Owner.GetActorName()}"); - Log.Debug("Start Play SKill[{0}]", skillId); - - var skillBaseConfig = ConfigLoader.Instance.Tables.TbSkill.Get(skillId); - - if (skillBaseConfig == null) - { - Log.Error("GetSkillBaseConfig Failed, invalid skillID: {0}", skillId); - return; - } - - - } - } -} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillCasterComponent.cs.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillCasterComponent.cs.meta deleted file mode 100644 index f1ba36aa..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillCasterComponent.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 9b445989d175457db064ef74adeb4181 -timeCreated: 1689582410 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillData.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillData.meta deleted file mode 100644 index 8ce14534..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillData.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 0c20684aa6954a80abe88ef8ee599800 -timeCreated: 1689585664 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillData/SkillDisplayData.cs b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillData/SkillDisplayData.cs deleted file mode 100644 index 879f0fae..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillData/SkillDisplayData.cs +++ /dev/null @@ -1,14 +0,0 @@ -using System; - -namespace GameLogic.BattleDemo -{ - /// - /// 技能表现数据。 - /// 表现数据再由SkillElementData组成。 - /// - [Serializable] - public class SkillDisplayData - { - - } -} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillData/SkillDisplayData.cs.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillData/SkillDisplayData.cs.meta deleted file mode 100644 index db66dcba..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillData/SkillDisplayData.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 7ffa4d74525b4c55ac6013a4372c6d42 -timeCreated: 1689586727 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillData/SkillPlayData.cs b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillData/SkillPlayData.cs deleted file mode 100644 index b21cf9a0..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillData/SkillPlayData.cs +++ /dev/null @@ -1,232 +0,0 @@ -using System.Collections.Generic; -using GameConfig.Battle; -using TEngine; - -namespace GameLogic.BattleDemo -{ - public enum SkillPlayStatus - { - /// - /// 初始状态。 - /// - PlayInit, - - /// - /// 技能施法前摇。 - /// 播放动作阶段。 - /// - PlayingAim, - - /// - /// 播放技能阶段,该阶段同时只能有一个技能播放。 - /// - PlayingFront, - - /// - /// 后台播放阶段,前台播放完后,可能还有一些元素要继续生效,这个时候转为后台播放阶段。 - /// 同时玩家可以释放新的技能。 - /// - PlayingBack, - - /// - /// 播放完毕,等待播放. - /// - PlayingToFree - } - - /// - /// 技能播放的数据。 - /// - public class SkillPlayData:IMemory - { - /// - /// 技能内存Id,代表该玩家当前的唯一技能Id。 - /// - public uint skillGid = 0; - - /// - /// 技能的配置Id。 - /// - public uint skillId; - - /// - /// 技能的配置。 - /// - public SkillBaseConfig skillBaseConfig; - - /// - /// 技能表现ID. - /// - public int skillDisplayId; - - /// - /// 技能表现数据。 - /// - public SkillDisplayData skillDisplayData; - - /// - /// 是否已经创建过visual表现层。 - /// - public bool HasVisualPlayData = false; - - /// - /// 开始时间。 - /// - public float startTime; - - /// - /// 开始技能进入后台的时间。 - /// - public float startBackTime; - - private SkillPlayStatus _status = SkillPlayStatus.PlayInit; - - /// - /// 播放状态 - /// - public SkillPlayStatus Status - { - set - { - if (_status != value) - { - _status = value; - if (_status == SkillPlayStatus.PlayingBack) - { - startBackTime = GameTime.time; - } - } - } - get => _status; - } - - public bool IsFrontStatus => _status == SkillPlayStatus.PlayingAim || _status == SkillPlayStatus.PlayingFront; - - public bool IsRunningStatus => _status == SkillPlayStatus.PlayingFront || _status == SkillPlayStatus.PlayingBack; - - private EntityLogic _casterActor = null; - private SkillCasterComponent _skillCaster = null; - - /// - /// 获取技能施法者。 - /// - public EntityLogic CasterActor - { - get => _casterActor; - - set - { - _casterActor = value; - _skillCaster = _casterActor.SkillCaster; - } - } - - /// - /// 获取施法者的运行时ID。 - /// - public long CasterId - { - get - { - if (_casterActor != null) - { - return _casterActor.RuntimeId; - } - - return 0; - } - } - - /// - /// 目标对象。 - /// - public EntityLogic targetActor; - - /// - /// 获取技能播放模块。 - /// - internal SkillCasterComponent SkillCaster => _skillCaster; - - /// - /// 处理动画元素。 - /// - internal SkillAnimationHandle animHandle; - - /// - /// 技能元素处理列表。 - /// - internal List handleList = new List(); - - public void Clear() - { - skillId = 0; - skillGid = 0; - skillDisplayId = 0; - skillDisplayData = null; - skillBaseConfig = null; - - Status = SkillPlayStatus.PlayInit; - startTime = 0; - startBackTime = 0; - - CasterActor = null; - targetActor = null; - DestroyAllElement(); - } - - private void DestroyAllElement() - { - //销毁所有的ElementHandle - foreach (var elemHandle in handleList) - { - elemHandle?.Destroy(); - } - handleList.Clear(); - animHandle = null; - } - - /// - /// 增加技能元素处理。 - /// - /// 技能元素处理。 - /// 是否增加成功。 - internal bool AddElementHandle(SkillElementHandle handle) - { - string errField = null; - string checkResult = handle.CheckElementConfig(ref errField); - if (!string.IsNullOrEmpty(checkResult)) - { - Log.Warning("skill Element config[{0}] error: {1}, RandomSkillLibraryId[{2}]", handle.GetType().ToString(), checkResult, skillId); - return false; - } - handleList.Add(handle); - return true; - } - - /// - /// 创建表现层技能对象。 - /// - internal void CreateVisualObject() - { - if (HasVisualPlayData) - { - return; - } - HasVisualPlayData = true; - //发送给visual事件 - //TODO - } - - /// - /// 销毁表现层技能对象。 - /// - internal void DestroyVisualObject() - { - if (HasVisualPlayData && _casterActor != null) - { - HasVisualPlayData = false; - //TODO - } - } - } -} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillData/SkillPlayData.cs.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillData/SkillPlayData.cs.meta deleted file mode 100644 index 4f12c859..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillData/SkillPlayData.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 05013b249849443eb8c5cb10491233ed -timeCreated: 1689586140 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementData.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementData.meta deleted file mode 100644 index 009172cd..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementData.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 29cd06d7bab9405481fc35365616dac3 -timeCreated: 1689587459 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementData/SkillElementData.cs b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementData/SkillElementData.cs deleted file mode 100644 index ebc9d882..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementData/SkillElementData.cs +++ /dev/null @@ -1,7 +0,0 @@ -namespace GameLogic.BattleDemo -{ - public abstract class SkillElementData - { - - } -} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementData/SkillElementData.cs.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementData/SkillElementData.cs.meta deleted file mode 100644 index a27b4ecc..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementData/SkillElementData.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 7d6aefa939104f9d89a18ab78e385d05 -timeCreated: 1689587502 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementData/SkillTriggerEvent.cs b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementData/SkillTriggerEvent.cs deleted file mode 100644 index 4ec64512..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementData/SkillTriggerEvent.cs +++ /dev/null @@ -1,23 +0,0 @@ -using System; - -namespace GameLogic.BattleDemo -{ - [Serializable] - public enum SkillTriggerEvent - { - /// - /// 无触发。 - /// - NoneEvent, - - /// - /// 时间点触发。 - /// - TimeEvent, - - /// - /// 施法结束触发。 - /// - AnimStopEvent, - } -} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementData/SkillTriggerEvent.cs.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementData/SkillTriggerEvent.cs.meta deleted file mode 100644 index 6a0596dc..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementData/SkillTriggerEvent.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 0413bfaea7674c68bde372498c15cc2d -timeCreated: 1689588039 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementHandle.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementHandle.meta deleted file mode 100644 index 72297f63..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementHandle.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 503ad5f03b8b4f8aab31436f9c5f44eb -timeCreated: 1689587434 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementHandle/SkillAnimationHandle.cs b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementHandle/SkillAnimationHandle.cs deleted file mode 100644 index 8639101b..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementHandle/SkillAnimationHandle.cs +++ /dev/null @@ -1,7 +0,0 @@ -namespace GameLogic.BattleDemo -{ - public class SkillAnimationHandle:SkillElementHandle - { - - } -} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementHandle/SkillAnimationHandle.cs.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementHandle/SkillAnimationHandle.cs.meta deleted file mode 100644 index ed106565..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementHandle/SkillAnimationHandle.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: f93a8f3fc1e34bb8a03bdb3c0ba56e27 -timeCreated: 1689587524 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementHandle/SkillElementHandle.cs b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementHandle/SkillElementHandle.cs deleted file mode 100644 index 35e41549..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementHandle/SkillElementHandle.cs +++ /dev/null @@ -1,152 +0,0 @@ -using GameConfig.Battle; -using TEngine; - -namespace GameLogic.BattleDemo -{ - /// - /// 每个元素的状态。 - /// - public enum SkillElementStatus - { - /// - /// 元素状态初始化。 - /// - ELEM_STATUS_INIT, - - /// - /// 元素状态运行中。 - /// - ELEM_STATUS_RUN, - - /// - /// 元素状态停止。 - /// - ELEM_STATUS_STOP - } - - public abstract class SkillElementHandle - { - private static uint m_nextHandleGID = 1; - - public uint m_handleGID; - public EntityLogic CasterActor; - protected uint m_skillId; - protected SkillAttrDamageData[] m_damageAttr; - - protected SkillPlayData m_playData; - public SkillElementStatus Status = SkillElementStatus.ELEM_STATUS_INIT; - - public void Destroy() - { - if (Status == SkillElementStatus.ELEM_STATUS_RUN) - { - Stop(); - } - - OnDestroy(); - } - - /// - /// 初始化接口 - /// - public void Init(SkillPlayData playData, SkillAttrDamageData[] damageAttr) - { - m_handleGID = m_nextHandleGID++; - CasterActor = playData.CasterActor; - m_skillId = playData.skillId; - m_playData = playData; - m_damageAttr = damageAttr; - - Status = SkillElementStatus.ELEM_STATUS_INIT; - OnInit(); - } - - /// - /// 触发Element开始。 - /// - /// 技能播放数据。 - /// 技能触发类型。 - public void Start(SkillPlayData playData, SkillTriggerEvent eventType) - { - if (Status != SkillElementStatus.ELEM_STATUS_INIT) - { - Log.Error("invalid status skillId[{0}] element Type[{1}]", m_skillId, GetType().Name); - return; - } - - Status = SkillElementStatus.ELEM_STATUS_RUN; - - //如果是重复触发的机制,则不需要开始就触发。 - OnStart(playData, eventType); - } - - /// - /// 触发Element结束。 - /// - public void Stop() - { - if (Status == SkillElementStatus.ELEM_STATUS_STOP) - { - return; - } - - if (Status != SkillElementStatus.ELEM_STATUS_RUN) - { - Status = SkillElementStatus.ELEM_STATUS_STOP; - return; - } - - Status = SkillElementStatus.ELEM_STATUS_STOP; - OnStop(); - } - - #region override function - - /// - /// 检查配置是否正常 - /// - /// - public virtual string CheckElementConfig(ref string errField) - { - return null; - } - - /// - /// 初始化一些数,在加入到技能列表的时候触发 - /// - protected virtual void OnInit() - { - } - - /// - /// 触发销毁。 - /// - protected virtual void OnDestroy() - { - } - - /// - /// 触发开始 - /// - /// 触发开始的消息类型 - /// 触发开始的消息类型 - protected virtual void OnStart(SkillPlayData playData, SkillTriggerEvent eventType) - { - } - - /// - /// 触发结束。 - /// - protected virtual void OnStop() - { - } - - /// - /// 调试绘制。 - /// - public virtual void OnDrawGizmos() - { - } - #endregion - } -} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementHandle/SkillElementHandle.cs.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementHandle/SkillElementHandle.cs.meta deleted file mode 100644 index 52c6b62f..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Logic/Skill/SkillElementHandle/SkillElementHandle.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 689c542f2f41447395080f93982a872f -timeCreated: 1689587448 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual.meta deleted file mode 100644 index de49e3a1..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: fad718b498934a5d8c63aa6d1e115485 -timeCreated: 1689576347 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/Display.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/Display.meta deleted file mode 100644 index 28156186..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/Display.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 489220b19d954b69be5e170287e92210 -timeCreated: 1689584174 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/Display/DisplayComponent.cs b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/Display/DisplayComponent.cs deleted file mode 100644 index 0c1e61da..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/Display/DisplayComponent.cs +++ /dev/null @@ -1,18 +0,0 @@ -using TEngine; - -namespace GameLogic.BattleDemo -{ - /// - /// 外观显示组件。 - /// - public class DisplayComponent:EntityLogicComponent - { - public DisplayInfo displayInfo; - - public override void Dispose() - { - MemoryPool.Release(displayInfo); - base.Dispose(); - } - } -} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/Display/DisplayComponent.cs.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/Display/DisplayComponent.cs.meta deleted file mode 100644 index 879eb152..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/Display/DisplayComponent.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: e1b7fbc52816477c9fc7de9eabe17667 -timeCreated: 1689582273 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/Display/DisplayInfo.cs b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/Display/DisplayInfo.cs deleted file mode 100644 index d8f45684..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/Display/DisplayInfo.cs +++ /dev/null @@ -1,12 +0,0 @@ -using TEngine; - -namespace GameLogic.BattleDemo -{ - public class DisplayInfo:IMemory - { - public void Clear() - { - throw new System.NotImplementedException(); - } - } -} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/Display/DisplayInfo.cs.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/Display/DisplayInfo.cs.meta deleted file mode 100644 index da2ca0ad..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/Display/DisplayInfo.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 7ee020b854aa4c62b684df994d73ad7a -timeCreated: 1689585424 \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/EntityVisual.cs b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/EntityVisual.cs deleted file mode 100644 index a7be02aa..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/EntityVisual.cs +++ /dev/null @@ -1,14 +0,0 @@ -using UnityEngine; - -namespace GameLogic.BattleDemo -{ - /// - /// 表现层实体。 - /// - public abstract class EntityVisual:MonoBehaviour - { - public EntityLogic Entity { protected set; get;} - - - } -} \ No newline at end of file diff --git a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/EntityVisual.cs.meta b/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/EntityVisual.cs.meta deleted file mode 100644 index c1cfb725..00000000 --- a/Assets/GameScripts/HotFix/GameLogic/BattleDemo/Core/Visual/EntityVisual.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 892288dabf264b20b49b03ae91ccf5f8 -timeCreated: 1689576255 \ No newline at end of file