Unity シーンの切り替えと同時にSEを再生すると途切れてしまう。
画面をクリックした際に画面の切り替えとSEの再生処理を同時に行う処理を行うと、短時間のSEが一瞬で途切れてしまいます。
どのような解決方法がありますか?
コード using System.Collections; using System.Collections.Generic; using UnityEngine; using UnityEngine.SceneManagement; public class StartDirector : MonoBehaviour { private AudioSource sound01; // Use this for initialization void Start () { AudioSource[] audioSources = GetComponents<AudioSource>(); sound01 = audioSources[1]; } // Update is called once per frame void Update () { if(Input.GetMouseButtonDown(0)) { sound01.PlayOneShot(sound01.clip); SceneManager.LoadScene("GameScene"); } } }
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。