fix: Previous/Next走对woman步进 + 开场动画支持重复播放
- PreviousStep/NextStep: woman自由步进优先于Config路径 - UpdateTouchVisibility: 修正索引 i==step (之前错误地用step-1) - PlayOpeningFlow: 每次调用前重置man/man2/摄像机状态,支持返回重来 - PageController: 移除InitializeFromGameManager调用,不再覆盖woman步进
This commit is contained in:
@@ -87,6 +87,24 @@ public class OpeningFlowController : MonoBehaviour
|
||||
public void PlayOpeningFlow(System.Action onComplete)
|
||||
{
|
||||
Debug.Log("[OpeningFlow] PlayOpeningFlow() 被调用");
|
||||
|
||||
// 每次播放前重置场景(支持重复播放)
|
||||
if (_manAnimator != null)
|
||||
{
|
||||
_manAnimator.gameObject.SetActive(true);
|
||||
_manAnimator.SetBool("IsStart", false);
|
||||
_manAnimator.SetBool("IsFull", false);
|
||||
}
|
||||
if (_man2Object != null) _man2Object.SetActive(true);
|
||||
if (_womanObject != null) _womanObject.SetActive(false);
|
||||
if (_manInjuryObject != null) _manInjuryObject.SetActive(false);
|
||||
if (_blackScreenPanel != null) _blackScreenPanel.SetActive(false);
|
||||
|
||||
var mainCam = Camera.main;
|
||||
if (mainCam != null) mainCam.enabled = true;
|
||||
var cam2 = GameObject.Find("camera2");
|
||||
if (cam2 != null) { var c = cam2.GetComponent<Camera>(); if (c != null) c.enabled = false; }
|
||||
|
||||
StartCoroutine(RunOpeningFlow(onComplete));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user