diff --git a/Assets/Scripts/UI/PageController.cs b/Assets/Scripts/UI/PageController.cs index f0e4ace..bffc91a 100644 --- a/Assets/Scripts/UI/PageController.cs +++ b/Assets/Scripts/UI/PageController.cs @@ -335,11 +335,9 @@ public class PageController : MonoBehaviour private void StopBgMusic() { if (_fadeCoroutine != null) { StopCoroutine(_fadeCoroutine); _fadeCoroutine = null; } - if (_bgAudioSource != null) - { - _bgAudioSource.Stop(); - Debug.Log("PageController: 停止背景音乐"); - } + var allSrcs = gameObject.GetComponents(); + foreach (var s in allSrcs) { if (s != null) s.Stop(); } + Debug.Log("PageController: 停止背景音乐 (共" + allSrcs.Length + "个AudioSource)"); } private void PlayExperimentBg()