新增了一个进出维修室的表现指令
This commit is contained in:
@@ -4,6 +4,7 @@ using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
using UnityEngine.Events;
|
||||
using Yarn.Unity;
|
||||
using DG.Tweening;
|
||||
|
||||
namespace AibisDream
|
||||
{
|
||||
@@ -251,6 +252,33 @@ namespace AibisDream
|
||||
{
|
||||
return MainUIController.Instance.HideObj();
|
||||
}
|
||||
[YarnCommand("move_to_fix")]
|
||||
public static IEnumerator Move_to_fix()
|
||||
{
|
||||
bool isCompleted = false;
|
||||
Sequence s = DOTween.Sequence();
|
||||
s.Append(Camera.main.transform.DOMove(new UnityEngine.Vector3(6.8f, 0, -10), 1.5f).SetEase(Ease.OutCubic))
|
||||
.OnComplete(() =>
|
||||
{
|
||||
// 动画完成后的反馈操作
|
||||
Debug.Log("Move_to_fix sequence completed.");
|
||||
isCompleted = true;
|
||||
});
|
||||
|
||||
// 等待动画完成
|
||||
yield return new WaitUntil(() => isCompleted);
|
||||
|
||||
// 动画完成后的其他操作
|
||||
Debug.Log("Continuing after Move_to_fix sequence.");
|
||||
}
|
||||
[YarnCommand("move_out_fix")]
|
||||
public static void Move_out_fix()
|
||||
{
|
||||
Camera.main.transform.position=new UnityEngine.Vector3(6.8f, 0, -10);
|
||||
Sequence s = DOTween.Sequence();
|
||||
//s.AppendInterval(0.5f);
|
||||
s.Append(Camera.main.transform.DOMove(new UnityEngine.Vector3(0, 0, -10), 1.5f).SetEase(Ease.OutCubic));
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user