Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

How do I fix this music / Sound ?[Unanswered]

Variable=Instance.new("Sound",game.Workspace) Variable=SoundId="http://www.roblox.com/Bleach-opening-2-item?id=169344914" Variable:Play() Variable.Looped=true

5 comments

0

Incorrect URL; That URL will not work.

0

@TheAplhaStigma Make the URL Shorter?

0

I answered on the other one. Go check that.

0

Not exactly, you did not give .lua a Valid URL, the .lua usually allows 'http://www.roblox.com/asset/?id=Num' or 'rbxassetid://Num'. The WIKI on this (kinda) link is here: http://wiki.roblox.com/index.php?title=SoundId

0

Also, do not Re-post the same Question over and over just to get an Answer; Be patient, otherwise, you will be Moderated, and this will be considered 'Spam'.

2 answers

I already posted this on your other question, but just make sure, here ya go:

Variable=Instance.new("Sound",game.Workspace)
Variable.SoundId="rbxassetid://169344914" --Use this format
Variable:Play()
Variable.Looped=true --You were telling the workspace to play...which it can't

Use this now. Hope I helped :P

I'll explain the reason behind dyler3's Answer, because I think he forgot to mention why it was not playing in the first place; He only provided code, sadly, and not a lot of explanation. :c

Your problem (I noticed) is that you are not giving .lua a Valid URL, thus, it is not Playing anything because of you giving .lua a, to it, false or fake URL.

This can be fixed, however, but, please keep in mind that the link you used before is NOT a Valid URL to .lua.

The Language, however, does accept these URLs';

local URL1 = "http://www.roblox.com/asset/?id=12345" --This is one of the URL types that .lua accepts

local URL2 = "rbxassetid://12345" --This is yet another URL that .lua accepts

local URL3 = "http://www.roblox.com/--------item?id=233521835"
--To .lua, this type of URL is not a real URL, or, takes it as a fake (meaning it thinks your giving it a fake/invalid link/URL, and so the error)

Hope this helped!

This discussion is preserved as it was. New answers, comments, and votes are closed.