public SmoothLoopMusicPlayer(SmoothLoopAudioClip clip) { GameObject obj = new GameObject("SmoothLoopMusicPlayer (" + clip + ")"); SmoothLoopAudioSource source = obj.AddComponent <SmoothLoopAudioSource>(); source.music = clip; this.source = source; UnityEngine.Object.DontDestroyOnLoad(obj); }
public SmoothLoopMusicAsset(SmoothLoopAudioClip clip) { this.clip = clip; }