Just wondering if its possible to play part of an AudioClip, rather than splicing it up into smaller AudioClips?
For example, something like this (which isn’t working).
Thanks
public IEnumerator PlaySectionOfClip(int audioID, float TimeFrom, float TimeTo)
{
if (!gameObject.audio.isPlaying)
{
if (audioID < SoundSelection.Length)
{
gameObject.audio.clip = SoundSelection[audioID];
gameObject.audio.Play();
gameObject.audio.time = TimeFrom;
yield return new WaitForSeconds(TimeTo - TimeFrom);
gameObject.audio.Stop();
yield return null;
// StopAudio();
}
}
}