I have a sound player which plays a song whenever a player respawns / switch to a different song. The problem however is that there’s a rare chance that the song cannot be heard at all once this happens, while the sound object shows every sign it is playing (isPlaying = true, Playing = true, pitch and volume are at normal values and TimePosition keep increasing).
With these signs I assume nothing’s wrong with my sound player, and I’m assuming something is wrong with sound objects.
Has this only happened when sounds are played for the first time?
Regardless of the above is true, will re-playing the sound fix the issue?
Is Sound.IsLoaded true?
Please post code, and IsLoaded and SoundLength status when this happens.
@Echo: This can happen even after a sound is used multiple times. Re-playing, as well as altering other values as Pitch, TimePosition and Volume, won’t solve the problem as the sound is already playing. Sound.IsLoaded is true.
I’m able to replicate it by keep changing songs after they are working properly. This is what the sound object shows whenever this bug occurs:
So far everything looks fine, but in-game the sound isn’t heard. There’s also no output given on the server, nor the client.
Here’s a footage of what a streamer caught in-game: - YouTube
He first spawns with songs working fine, but the next time he spawns the song cannot be heard. He also tries to mute / unmute it later but that doesn’t work as it only alters the Volume. He then resets as this resets the sound.
Here’s the sound player I’m using: MusicScript.rbxm (9.3 KB)
Lastly the place this is happening: A ROBLOX Quest: Elements of Robloxia - Roblox
I’ve modified your code to change song every click, and I cannot get the behaviour you mentioned. Can you try to reproduce the same problem modifying this place?
btl23.rbxl (22.3 KB)
Have send you a pm with the reproduction