So my question is this: What’s the best place to store game sounds, like music, to be played later by both client and server scripts?
I originally thought the best place to keep them was ReplicatedStorage, as it replicates to both server and client.
However, I later discovered sounds played from there by the server don’t actually play.
Same thing with SoundService.
So is Workspace really the best place to keep sounds like music and such?
Where do you guys keep/think is the best place to keep them?
Ah, you mean SoundService.
This works for local scripts, but server scripts can’t play sounds from here.
Wherever I keep them, they will preferably need to be playable by both client and server scripts.
I just have a guess, maybe it does have a position or something, is there a way to disable the range?
But as he said, you can just fire a remote event.
Good guess, but if it did have a position it would have to play form the center of the world (0,0,0), which it doesn’t.
Besides that though, wouldn’t it do the same on the client too if that where the case?
The fact this doesn’t work from SoundService is already weird to me.
That’s honestly quite odd, I tried to play the sound from a server script once the player joined and it worked, but when I just used a wait() before that it didn’t.
Edit: I tried to set it to inf, it didn’t work.
Edit 2: I can’t understand this, it sometimes does work and sometimes doesn’t.
Peronsally i would keep them in Workspace, and sometimes i have seen there is a ‘Sound’ area within the ‘game’ created on play and maybe you can move them to there using a script or something (or put them there if its accessible via roblox studio itself.)
FYI: Sounds consume quite a bit of memory. Unless you immediately need them all at the same time I recommend using one Sound Instance and change it’s SoundId when needbe.
I know this was 11 months ago. Anyways, SoundScape is what SoundService used to be until they changed it.
Soundscape contained the original sounds like the Victory sound until it was named “SoundService”. They removed the old sounds. And now, soundService is made to put sounds in to.