From ee156b2a7254d58e646dc44f5828c7e1eb8e1b64 Mon Sep 17 00:00:00 2001 From: chai Date: Thu, 9 Sep 2021 11:37:27 +0800 Subject: *misc --- Assets/Scripts/Unit/AI/Actions.meta | 8 ++++++++ Assets/Scripts/Unit/AI/Conditionals.meta | 8 ++++++++ Assets/Scripts/Unit/Components/UnitAnimation/PCAnimation.cs | 7 +++---- 3 files changed, 19 insertions(+), 4 deletions(-) create mode 100644 Assets/Scripts/Unit/AI/Actions.meta create mode 100644 Assets/Scripts/Unit/AI/Conditionals.meta (limited to 'Assets/Scripts/Unit') diff --git a/Assets/Scripts/Unit/AI/Actions.meta b/Assets/Scripts/Unit/AI/Actions.meta new file mode 100644 index 00000000..9b4ad463 --- /dev/null +++ b/Assets/Scripts/Unit/AI/Actions.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 971e9d55b8bc0894eb6a110fb962000b +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Scripts/Unit/AI/Conditionals.meta b/Assets/Scripts/Unit/AI/Conditionals.meta new file mode 100644 index 00000000..70a86da5 --- /dev/null +++ b/Assets/Scripts/Unit/AI/Conditionals.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 85b7e0c7ed1d12f42a5178bfbf3d934c +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Scripts/Unit/Components/UnitAnimation/PCAnimation.cs b/Assets/Scripts/Unit/Components/UnitAnimation/PCAnimation.cs index cdffc8ed..32881dcd 100644 --- a/Assets/Scripts/Unit/Components/UnitAnimation/PCAnimation.cs +++ b/Assets/Scripts/Unit/Components/UnitAnimation/PCAnimation.cs @@ -151,7 +151,7 @@ public class PCAnimation : UnitAnimation return; } - AnimationData GetAnimationDataOfGivenState(string name) + AnimationData GetAnimationDataOfState(string name) { string animName = controller[name].name; string path = owner.folder + "AnimationData/" + animName + ".asset"; @@ -185,10 +185,10 @@ public class PCAnimation : UnitAnimation else if (id == 3) state = EAnimState.AirAttack3; else if (id == 4) state = EAnimState.AirAttack4; - AnimationData data = GetAnimationDataOfGivenState(state.ToString()); + AnimationData data = GetAnimationDataOfState(state.ToString()); Debug.Assert(data != null); float offset = data.GetProperty(EAnimationProperty.ComboTimeOffset, 0); - float duration = data.GetProperty(EAnimationProperty.TransitionInDuration, 0.05f); + float duration = data.GetProperty(EAnimationProperty.TransitionInDuration, 0.1f); CrossFade(state, duration, offset); } @@ -198,7 +198,6 @@ public class PCAnimation : UnitAnimation Play(EAnimState.AttackToAir, offset); } - public void AnimAttack(int id) { m_Owner.unitCollider.OnAnimationChange(); -- cgit v1.1-26-g67d0