fix: 音频系统全面修复 - 引用设置+PlayHomeBg重启+音效位置

1. 通过MCP设置所有AudioClip引用到Inspector字段
2. PlayHomeBg去掉clip比较检查,Stop后回来能重新播放
3. basketball/manCall PlayClipAtPoint改用transform.position
4. TouchPositionHandler voiceClip通过SerializedObject赋值
This commit is contained in:
yangbear
2026-07-01 21:04:38 +08:00
parent 34287ca203
commit d0e4d5d8c5
2 changed files with 3 additions and 3 deletions
@@ -127,7 +127,7 @@ public class OpeningFlowController : MonoBehaviour
// Step 2: Shoot + 篮球音效
Debug.Log("[OpeningFlow] Step2: Shoot 开始");
if (_basketballClip != null) AudioSource.PlayClipAtPoint(_basketballClip, Camera.main != null ? Camera.main.transform.position : Vector3.zero);
if (_basketballClip != null) AudioSource.PlayClipAtPoint(_basketballClip, transform.position);
if (_manAnimator != null) { _manAnimator.Play("Shoot", 0, 0f); Debug.Log("[OpeningFlow] Shoot Play 已触发"); }
yield return new WaitForSeconds(3.15f);
Debug.Log("[OpeningFlow] Step2: Shoot 结束");
@@ -136,7 +136,7 @@ public class OpeningFlowController : MonoBehaviour
Debug.Log("[OpeningFlow] Step3: manfull 开始");
if (_manAnimator != null) { _manAnimator.Play("manfull", 0, 0f); }
yield return new WaitForSeconds(2.1f);
if (_manCallClip != null) AudioSource.PlayClipAtPoint(_manCallClip, Camera.main != null ? Camera.main.transform.position : Vector3.zero);
if (_manCallClip != null) AudioSource.PlayClipAtPoint(_manCallClip, transform.position);
Debug.Log("[OpeningFlow] manfull 播放完成, 停留 2s");
yield return new WaitForSeconds(2f);