Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Making a sound play whenever a player join game (Question?)

Asked by 5 years ago

So i made this script that should play a sound whenever a player joins a game. But i have few questions Does the sound plays only once? Does the sound play for everyone or just the player who has joined? If it does how do you fix it? It is made for intro and shouldn't be played for everyone.

script.Parent.Sound.Playing = true
script.Parent.Sound.Volume = 1
script.Parent:Destroy()

1 answer

Log in to vote
0
Answered by 5 years ago

Put this into a Server Script into ServerScriptService.

game.Players.PlayerAdded:connect(function(player)
script.Parent.Sound.Playing = true
script.Parent.Sound.Volume = 1
script.Parent:Destroy()
end)
0
Also the sound does play once unless you enable looping. It plays just for the local user. IrishStukov 20 — 5y
Ad

Answer this question