generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: Please Help!!!

Previous Thread :: Next Thread 
xXBestPieXx is not online. xXBestPieXx
Joined: 08 Nov 2012
Total Posts: 1271
27 Jun 2014 01:40 AM
Everytime a person joins the game, it plays a sound. Whenever other people are online and a person joins the game, they hear the sound again! How do I make the sound play individually?
Report Abuse
BusyCityGuy is not online. BusyCityGuy
Joined: 17 Aug 2012
Total Posts: 2144
27 Jun 2014 01:43 AM
Put the sound in StarterGui or StarterPack.

game.Players.PlayerAdded:connect(function(player)
player.CharacterAdded:connect(function()
for i, v in ipairs(game.Players.GetChildren()) do
v.PlayerGui.Sound:Play()
wait(3)
v.PlayerGui.Sound:Stop()
end
end)
end)

-The [Guy]
Report Abuse
xXBestPieXx is not online. xXBestPieXx
Joined: 08 Nov 2012
Total Posts: 1271
27 Jun 2014 01:44 AM
Do I put this in a local script or regular?
Report Abuse
BusyCityGuy is not online. BusyCityGuy
Joined: 17 Aug 2012
Total Posts: 2144
27 Jun 2014 01:45 AM
Screw that.. that would play a sound every time someone spawned, haha.
Do this instead.

game.Players.PlayerAdded:connect(function()
for i, v in ipairs(game.Players:GetChildren()) do
v.PlayerGui.Sound:Play()
end
end)

I am not entirely sure if it will play and need to be stopped after it's played? If it doesn't work, then there's a simple fix.

-The [Guy]
Report Abuse
BusyCityGuy is not online. BusyCityGuy
Joined: 17 Aug 2012
Total Posts: 2144
27 Jun 2014 01:46 AM
Put that in a regular script in the Workspace.

-The [Guy]
Report Abuse
xXBestPieXx is not online. xXBestPieXx
Joined: 08 Nov 2012
Total Posts: 1271
27 Jun 2014 01:48 AM
Doesn't play at all...
Report Abuse
BusyCityGuy is not online. BusyCityGuy
Joined: 17 Aug 2012
Total Posts: 2144
27 Jun 2014 01:49 AM
Make sure your sound is named "Sound"?

-The [Guy]
Report Abuse
xXBestPieXx is not online. xXBestPieXx
Joined: 08 Nov 2012
Total Posts: 1271
27 Jun 2014 01:50 AM
It is "Sound"
Report Abuse
BusyCityGuy is not online. BusyCityGuy
Joined: 17 Aug 2012
Total Posts: 2144
27 Jun 2014 01:50 AM
And make sure it's in the PlayerGui, that's where I have the script point to.

-The [Guy]
Report Abuse
xXBestPieXx is not online. xXBestPieXx
Joined: 08 Nov 2012
Total Posts: 1271
27 Jun 2014 01:51 AM
Once I put the sound in StarterGui, when I run it, it goes into PlayerGui. So that's good also.
Report Abuse
xXBestPieXx is not online. xXBestPieXx
Joined: 08 Nov 2012
Total Posts: 1271
27 Jun 2014 01:58 AM
Any other suggestions please?
Report Abuse
xXBestPieXx is not online. xXBestPieXx
Joined: 08 Nov 2012
Total Posts: 1271
27 Jun 2014 02:12 AM
Anyone? Please help!
Report Abuse
xXBestPieXx is not online. xXBestPieXx
Joined: 08 Nov 2012
Total Posts: 1271
27 Jun 2014 02:24 AM
Please help!!!
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image