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: Play sound via script, output is I don't have permission

Previous Thread :: Next Thread 
Lapwn is not online. Lapwn
Joined: 03 Jun 2012
Total Posts: 5975
29 Mar 2015 01:40 PM
The sounds aren't created by me but they are in my inventory, can I only use sounds created by me?
Report Abuse
Argelius is not online. Argelius
Joined: 19 Jul 2010
Total Posts: 4047
29 Mar 2015 01:42 PM
It doesn't even have to be in your inventory to play it, you can play any sounds you want I believe.
Report Abuse
Lapwn is not online. Lapwn
Joined: 03 Jun 2012
Total Posts: 5975
29 Mar 2015 01:50 PM
Roblox hates me then :(

No you can play sounds if you start them without a script but if you try with a script it wont work.

This is what I used

function onPlayerEntered(nP)
wait()
local h = game.ReplicatedStorage.Sound:Clone()
h.Parent = nP.PlayerGui
h:Play()
end

I also did this

function onPlayerEntered(nP)
wait()
local h = game.ReplicatedStorage.Sound:Clone()
h.Parent = nP.PlayerGui
h.SoundId = "http://www.roblox.com/asset?id=143897077"
h:Play()
end
Report Abuse
Argelius is not online. Argelius
Joined: 19 Jul 2010
Total Posts: 4047
29 Mar 2015 01:53 PM
h.SoundId should be the actual ID not the URL
Report Abuse
Lapwn is not online. Lapwn
Joined: 03 Jun 2012
Total Posts: 5975
29 Mar 2015 02:05 PM
Oh, how do I get the url?
Report Abuse
Lapwn is not online. Lapwn
Joined: 03 Jun 2012
Total Posts: 5975
29 Mar 2015 02:06 PM
I mean id x.x
Report Abuse
Argelius is not online. Argelius
Joined: 19 Jul 2010
Total Posts: 4047
29 Mar 2015 02:06 PM
the end of the url that says 'id=143897077', so the id is 143897077
Report Abuse
Lapwn is not online. Lapwn
Joined: 03 Jun 2012
Total Posts: 5975
29 Mar 2015 02:09 PM
wait so I just put the id in without the asset part?
Report Abuse
Argelius is not online. Argelius
Joined: 19 Jul 2010
Total Posts: 4047
29 Mar 2015 02:12 PM
Do it like this:
rbxassetid://143897077
Report Abuse
Argelius is not online. Argelius
Joined: 19 Jul 2010
Total Posts: 4047
29 Mar 2015 02:13 PM
In case you forget, it's on the wiki
http://wiki.roblox.com/index.php?title=API:Class/Sound/SoundId
Report Abuse
Lapwn is not online. Lapwn
Joined: 03 Jun 2012
Total Posts: 5975
29 Mar 2015 02:21 PM
It automatically made it like that. Thanks though, I found out the problem in the sound tutorial u linked.

I was trying to play the sounds before they were loaded was what was wrong.
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