summaryrefslogtreecommitdiff
path: root/Assets/Scripts/Unit/TimelineEventProxy.cs
diff options
context:
space:
mode:
authorchai <chaifix@163.com>2021-09-02 09:59:31 +0800
committerchai <chaifix@163.com>2021-09-02 09:59:31 +0800
commit3ad68338dff5229d3fd8ec9f3ee994d7e37fb0ed (patch)
treeb5fbf74148147019f75dd4c078fd76f4804330ec /Assets/Scripts/Unit/TimelineEventProxy.cs
parentf7e60ab9a52e557aa2250477d018b2768bccc028 (diff)
*override rootmotion
Diffstat (limited to 'Assets/Scripts/Unit/TimelineEventProxy.cs')
-rw-r--r--Assets/Scripts/Unit/TimelineEventProxy.cs21
1 files changed, 15 insertions, 6 deletions
diff --git a/Assets/Scripts/Unit/TimelineEventProxy.cs b/Assets/Scripts/Unit/TimelineEventProxy.cs
index de067455..4a71400c 100644
--- a/Assets/Scripts/Unit/TimelineEventProxy.cs
+++ b/Assets/Scripts/Unit/TimelineEventProxy.cs
@@ -54,7 +54,8 @@ public partial class TimelineEventProxy
EventCamera_Blur, // 相机模糊
EventCamera_WhiteOut, // 相机白屏
- EventMesh_AfterImage, // 角色残像
+ EventMesh_AfterImage, // 角色残像
+ EventMesh_AfterImageStop, // 角色残像停止事件
EventMesh_FadeIn, // 角色透明度
EventMesh_FadeOut, // 角色透明度
EventMesh_Gloss, // 角色泛光
@@ -79,16 +80,16 @@ public partial class TimelineEventProxy
private Transform m_Root;
- private UnitController m_Owner;
+ public UnitController owner { get; private set; }
- private UnitAnimation m_UnitAnimation { get { return m_Owner.unitAnimation; } }
+ private UnitAnimation m_UnitAnimation { get { return owner.unitAnimation; } }
private AnimationData m_PrevAnimationData;
public TimelineEventProxy(Transform root, UnitController owner = null)
{
m_Root = root;
- m_Owner = owner;
+ this.owner = owner;
m_PrevAnimationData = null;
}
@@ -200,7 +201,7 @@ public partial class TimelineEventProxy
GameObject obj = GameObject.Instantiate(prefab);
Projectile projectile = obj.GetComponent<Projectile>();
ProjectileInfo info = new ProjectileInfo();
- info.owner = m_Owner;
+ info.owner = owner;
info.position = m_Root.transform.position + e.posOffset;
info.rotation = e.rotation;
info.scale = e.scale;
@@ -219,6 +220,14 @@ public partial class TimelineEventProxy
#endif
}
- #endregion
+ void EventMesh_AfterImage(AnimationEventBase animEvent)
+ {
+ EventMesh_AfterImage afterImage = animEvent as EventMesh_AfterImage;
+ if (afterImage == null)
+ return ;
+
+ }
+
+ #endregion
} \ No newline at end of file