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 » Scripters
Home Search
 

Re: Where to put sound for playing to everyone?

Previous Thread :: Next Thread 
xLink123 is not online. xLink123
Joined: 07 Aug 2014
Total Posts: 11158
05 Jun 2015 08:18 PM
Putting a sound in workspace and using:

local s = script.Parent -- this is the location of the sound
while true do --repeats
wait() -- you need this or the script will crash your roblox game
s:Play() --this plays the sound
end -- end



doesnt seem to play it at all
Report Abuse
TimeTicks is not online. TimeTicks
Joined: 27 Apr 2011
Total Posts: 27115
05 Jun 2015 08:19 PM
repeat wait() until game.Players.NumPlayers > 0

game.Workspace.Sound:Play()
Report Abuse
lazman15 is not online. lazman15
Joined: 07 Aug 2009
Total Posts: 116
05 Jun 2015 08:21 PM
Umm...

local sndid = "SoundIdHere"

local snd = Instance.new("Sound",game.Workspace)
snd.Looped = true
snd.SoundId = ("rbxassetid://"(sndid))
snd:Play()
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • 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