Audiosource crashes the second time

100 Views Asked by At

Program in Unity C# build for WebGL.
The program shows a cover page with background sound, then shows pages one by one, each page has a background sound and a voice sound. The first time it works fine: it shows the cover, click on Start, then shows the pages, and return to the cover, but the second time it crashes: while in the cover click on Start, shows the page with background sound but without the voice sound.
I get this message in console: Channel.playSoundClip error. Exception: TypeError: Failed to execute 'start' on 'AudioBufferSourceNode': The provided double value is non-finite.

Attributes in console show correct values.

time=0  
isFinite=true  
pitch=1
DecompressOnLoad type
loadState=loaded

Could this be a problem of two AudioSource interfering?

When I load the pages I load the audios each time, and then when I change page I stop the voice sound, to load another.

0

There are 0 best solutions below