So I have been seeing this error quite a bit - and it’s getting to be a bit of a problem.
We load a bunch of assets, with sound components attached and then instantiate them as required in game (we are using the offline engine).
It seems that frequently - we see errors thrown from PlayCanvas, where it attempts to call the WebAudio API - setPosition, with data either position, or rotation, that contains NaN values. How this is possible in the first place is a mystery - but I am guessing there is some race condition here. The reason I say it is a mystery is that every object should have positional and rotational data at all points during their lifecycle. I am guessing (although I haven not being able to verify this) - that the issue occurs when cloning the asset. I caught a crash recently where the Euler angles on the entity were set, but the localRotation values where NaN - and I believe it is this value that is used by the audio system.
Similarly - if you have an AudioListener component attached while cloning the asset, it causes a hard crash.
(This is the error as caused by a Sound Component being updated while the parent entity has NaN for it’s transform and localRotation values)
This is a snip of the entity for the object that is causing the problem - you can see localRotation has NaN values: