|
@@ -53,6 +53,8 @@ namespace GameLogic.Combat.Skill.MagicSkill
|
|
|
moveTime += t * addT;
|
|
|
Vector3 d = Vector3.Lerp(pos, endPos, moveTime);
|
|
|
fxAILogicBasic.gameObject.transform.position = d;
|
|
|
+ Quaternion quaternion = Quaternion.LookRotation(dir);
|
|
|
+ fxAILogicBasic.gameObject.transform.rotation = quaternion;
|
|
|
if (moveTime >= 1)
|
|
|
{
|
|
|
fxAILogicBasic.Dispose();
|
|
@@ -78,17 +80,23 @@ namespace GameLogic.Combat.Skill.MagicSkill
|
|
|
private bool _isUpdae;
|
|
|
private IUnRegister _unRegister;
|
|
|
|
|
|
+ private TimeLineEventLogicGroupBasic _timeLineEventLogicGroupBasic;
|
|
|
+
|
|
|
protected override void ProMagicUseSkill()
|
|
|
{
|
|
|
+ _currTime = 0;
|
|
|
+ _isUpdae = false;
|
|
|
TimeLineEventLogicGroupBasic timeLineEventLogicGroupBasic = ActivationTimeLineData("sk1_xiaoshi");
|
|
|
timeLineEventLogicGroupBasic.TimeLineUpdateEnd = delegate()
|
|
|
{
|
|
|
+ Vector3 targetPos = CombatMagicWeaponEntity.RootMagicWeaponControl.combatHeroEntity
|
|
|
+ .GetSpecialDotInfo("toupos2").GetWorlPos();
|
|
|
Transform root = CombatMagicWeaponEntity.RootMagicWeaponControl.combatHeroEntity.GameObject.transform;
|
|
|
- Vector3 pos = root.TransformPoint(new Vector3(0, 4, 4));
|
|
|
- Quaternion quaternion = Quaternion.Euler(120, 0, 0);
|
|
|
+ // Vector3 pos = root.TransformPoint(new Vector3(0, 4, 4));
|
|
|
+ Quaternion quaternion = Quaternion.Euler(110, 0, 0);
|
|
|
CombatHeroEntity.GameObject.transform.rotation = root.rotation * quaternion;
|
|
|
// Vector3 d = root.rotation * _dir;
|
|
|
- CombatHeroEntity.GameObject.transform.position = pos;
|
|
|
+ CombatHeroEntity.GameObject.transform.position = targetPos;
|
|
|
TimeLineEventLogicGroupBasic sk1_show = ActivationTimeLineData("sk1_show");
|
|
|
sk1_show.TimeLineUpdateEnd = ShowFinish;
|
|
|
};
|
|
@@ -96,7 +104,7 @@ namespace GameLogic.Combat.Skill.MagicSkill
|
|
|
|
|
|
protected void ShowFinish()
|
|
|
{
|
|
|
- ActivationTimeLineData("sk1");
|
|
|
+ _timeLineEventLogicGroupBasic = ActivationTimeLineData("sk1");
|
|
|
SpecialDotInfo specialDotInfo =
|
|
|
CombatMagicWeaponEntity.GetSpecialDotInfo("sk1");
|
|
|
_unRegister = specialDotInfo.targetTran.gameObject.OnTriggerEnterEvent(this, OnTriggerExitEvent);
|
|
@@ -125,6 +133,12 @@ namespace GameLogic.Combat.Skill.MagicSkill
|
|
|
if (_currTime > effectValue[1])
|
|
|
{
|
|
|
_isUpdae = false;
|
|
|
+ if (_timeLineEventLogicGroupBasic != null)
|
|
|
+ {
|
|
|
+ _timeLineEventLogicGroupBasic.CloseLoopFx();
|
|
|
+ }
|
|
|
+
|
|
|
+ ActivationTimeLineData("sk1_xiaoshi");
|
|
|
SkillPlayFinish();
|
|
|
}
|
|
|
}
|
|
@@ -133,7 +147,7 @@ namespace GameLogic.Combat.Skill.MagicSkill
|
|
|
{
|
|
|
_isUpdae = false;
|
|
|
|
|
|
-
|
|
|
+ _currTime = 0;
|
|
|
_unRegister.UnRegister();
|
|
|
CombatHeroEntity.CloseLoopFx();
|
|
|
}
|