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: audio playing help

Previous Thread :: Next Thread 
GFXdylan is not online. GFXdylan
Joined: 09 Feb 2013
Total Posts: 679
28 Mar 2014 07:27 AM
s = Instance.new("Sound")
s.Name = "pharrel-happy"
s.SoundId = "http://www.roblox.com/asset/?id=144075630"
s.Parent = game.Workspace
s:Play()
wait(161)
s:remove()


script.Parent.ClickDetector.MouseClick:connect(onClicked)



Is something wrong with this?
Report Abuse
getkoed is not online. getkoed
Joined: 18 Feb 2010
Total Posts: 2298
28 Mar 2014 07:30 AM
Yes. There is no function called onClicked.
Report Abuse
GFXdylan is not online. GFXdylan
Joined: 09 Feb 2013
Total Posts: 679
28 Mar 2014 07:32 AM
Man..
i want it like if i click on button it plays dis song..
going back in studio again..
Report Abuse
GFXdylan is not online. GFXdylan
Joined: 09 Feb 2013
Total Posts: 679
28 Mar 2014 07:34 AM
maar, kan je me helpen om dit te fixen?

but, can you help me to fix this?
Report Abuse
Clickest is not online. Clickest
Joined: 06 Aug 2013
Total Posts: 6504
28 Mar 2014 07:36 AM
function onClick()

s = Instance.new("Sound")
s.Name = "pharrel-happy"
s.SoundId = "http://www.roblox.com/asset/?id=144075630"
s.Parent = game.Workspace
s:Play()
wait(161)
s:remove()

end
script.Parent.ClickDetector.MouseClick:connect(onClicked)


ℭ - Frame
Report Abuse
GFXdylan is not online. GFXdylan
Joined: 09 Feb 2013
Total Posts: 679
28 Mar 2014 07:38 AM
yep i also had that in mind, thnx anyways
Report Abuse
tery215 is not online. tery215
Joined: 19 Aug 2009
Total Posts: 3879
28 Mar 2014 07:43 AM
function onClick()

s = Instance.new("Sound")
s.Name = "pharrel-happy"
s.SoundId = "http://www.roblox.com/asset/?id=144075630"
s.Parent = game.Workspace
s:Play()
game.Debris:AddItem(s, 161)

end
script.Parent.ClickDetector.MouseClick:connect(onClicked)
Report Abuse
GFXdylan is not online. GFXdylan
Joined: 09 Feb 2013
Total Posts: 679
28 Mar 2014 07:45 AM
doesnt work..
Report Abuse
Marolex is not online. Marolex
Joined: 17 Dec 2012
Total Posts: 1785
28 Mar 2014 07:49 AM
Do you have a click detector in the part?

-King Scrub
Report Abuse
GFXdylan is not online. GFXdylan
Joined: 09 Feb 2013
Total Posts: 679
28 Mar 2014 07:50 AM
yep
Report Abuse
tery215 is not online. tery215
Joined: 19 Aug 2009
Total Posts: 3879
28 Mar 2014 07:54 AM
function onClicked()

s = Instance.new("Sound", Workspace)
s.Name = "pharrel-happy"
s.SoundId = "http://www.roblox.com/asset/?id=144075630"
s:Play()
game.Debris:AddItem(s, 161)

end
script.Parent.ClickDetector.MouseClick:connect(onClicked)
Report Abuse
GFXdylan is not online. GFXdylan
Joined: 09 Feb 2013
Total Posts: 679
28 Mar 2014 08:06 AM
function onClicked()

s = Instance.new("Sound", Workspace)
sd = game.Workspace.songdisplayer.info.SurfaceGui
s.Name = "pharrel-happy"
s.SoundId = "http://www.roblox.com/asset/?id=144075630"
s:Play()
sd.song.Text = "Pharrel Williams - Happy (2min)"
wait(161)
s:remove()
sd.song.Text = "no song playing..."

end
script.Parent.ClickDetector.MouseClick:connect(onClicked)
Report Abuse
GFXdylan is not online. GFXdylan
Joined: 09 Feb 2013
Total Posts: 679
28 Mar 2014 08:10 AM
will that work
Report Abuse
GFXdylan is not online. GFXdylan
Joined: 09 Feb 2013
Total Posts: 679
28 Mar 2014 08:20 AM
halp
Report Abuse
GFXdylan is not online. GFXdylan
Joined: 09 Feb 2013
Total Posts: 679
28 Mar 2014 09:32 AM
will dis work man;
function onClicked()

s = Instance.new("Sound", Workspace)
sd = game.Workspace.songdisplayer.info.SurfaceGui
s.Name = "pharrel-happy"
s.SoundId = "http://www.roblox.com/asset/?id=144075630"
s:Play()
sd.song.Text = "Pharrel Williams - Happy (2min)"
wait(161)
s:remove()
sd.song.Text = "no song playing..."

end
script.Parent.ClickDetector.MouseClick:connect(onClicked)
Report Abuse
Looah is not online. Looah
Joined: 22 Feb 2013
Total Posts: 922
28 Mar 2014 09:37 AM
justusetheboolthatsaysithasstopped.
Report Abuse
tangyboxhead is not online. tangyboxhead
Joined: 23 Oct 2011
Total Posts: 9437
28 Mar 2014 09:38 AM
onthisthread5peoplehelpedwithsomethingthatiseasilyfixedintwosec.
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