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: How to make the music suddenly stop.

Previous Thread :: Next Thread 
cooldudexd10 is not online. cooldudexd10
Joined: 27 May 2012
Total Posts: 17159
01 Oct 2014 01:50 AM
So this is the script, there is an audio file there. To stop the music, should I say the command stop() or another command???

function onTouched(hit)
script.Parent.Ghost:play()
end
script.Parent.Touched:connect(onTouched)
Report Abuse
cooldudexd10 is not online. cooldudexd10
Joined: 27 May 2012
Total Posts: 17159
01 Oct 2014 01:51 AM
Sorry wrong forum.
Report Abuse
DurstAuric is not online. DurstAuric
Joined: 12 May 2009
Total Posts: 8066
01 Oct 2014 02:42 AM
function onTouched(hit)
script.Parent.Ghost:play()
end
script.Parent.Touched:connect(onTouched)
local script.Parent.Ghost:remove()
end

Try that.

R$103,948 ~#Durst~ P̕͝-̕R-̷̀͟Ǫ̷-̶͘X-҉̶Y ( ͡° ͜ʖ ͡°)
Report Abuse
cooldudexd10 is not online. cooldudexd10
Joined: 27 May 2012
Total Posts: 17159
01 Oct 2014 03:28 AM
I will go with destroy()
Remove just keeps it in the game but isn't removed and can be recovered.
Report Abuse
DurstAuric is not online. DurstAuric
Joined: 12 May 2009
Total Posts: 8066
01 Oct 2014 12:08 PM
That's the idea. If they reset, they'll hear it again..



R$108,713 ~#Durst~ P̕͝-̕R-̷̀͟Ǫ̷-̶͘X-҉̶Y ( ͡° ͜ʖ ͡°)
Report Abuse
DurstAuric is not online. DurstAuric
Joined: 12 May 2009
Total Posts: 8066
01 Oct 2014 12:08 PM
Let me fix it completely.



R$108,713 ~#Durst~ P̕͝-̕R-̷̀͟Ǫ̷-̶͘X-҉̶Y ( ͡° ͜ʖ ͡°)
Report Abuse
DurstAuric is not online. DurstAuric
Joined: 12 May 2009
Total Posts: 8066
01 Oct 2014 12:09 PM
function onTouched(hit)
local script.Parent.Ghost:play()
end
script.Parent.Touched:connect(onTouched)
local script.Parent.Ghost:remove()
end

That way, whenever the user walks on it, it'll only play for them.



R$108,713 ~#Durst~ P̕͝-̕R-̷̀͟Ǫ̷-̶͘X-҉̶Y ( ͡° ͜ʖ ͡°)
Report Abuse
qazqazq is not online. qazqazq
Joined: 13 Aug 2009
Total Posts: 973
01 Oct 2014 12:13 PM
What durst said

~Rainbow Dash of atr~
Report Abuse
DurstAuric is not online. DurstAuric
Joined: 12 May 2009
Total Posts: 8066
01 Oct 2014 12:49 PM
lmao



O ͜ O
Report Abuse
cooldudexd10 is not online. cooldudexd10
Joined: 27 May 2012
Total Posts: 17159
01 Oct 2014 01:00 PM
I am making a new horror game (because the GCC I made really sucked) so it will be 1 player server.
Report Abuse
DurstAuric is not online. DurstAuric
Joined: 12 May 2009
Total Posts: 8066
01 Oct 2014 01:10 PM
mk.



R$109,304 ~#Durst~ P̕͝-̕R-̷̀͟Ǫ̷-̶͘X-҉̶Y ( ͡° ͜ʖ ͡°)
Report Abuse
DurstAuric is not online. DurstAuric
Joined: 12 May 2009
Total Posts: 8066
01 Oct 2014 01:11 PM
Keep local, so if you reset, it'll work again.



R$109,304 ~#Durst~ P̕͝-̕R-̷̀͟Ǫ̷-̶͘X-҉̶Y ( ͡° ͜ʖ ͡°)
Report Abuse
Serkisx is not online. Serkisx
Joined: 25 May 2014
Total Posts: 4270
01 Oct 2014 01:11 PM
2 Player Co-op PLS.

"He has planted his arbolito in another garden." - Gordonrox24
Report Abuse
moistearlobe is not online. moistearlobe
Joined: 14 Sep 2014
Total Posts: 13
01 Oct 2014 01:17 PM
not wrong forum; there are scripters here too




- moistearlobe: a lazy man with ambitious goals.
Report Abuse
DurstAuric is not online. DurstAuric
Joined: 12 May 2009
Total Posts: 8066
01 Oct 2014 05:19 PM
if you can't die on the place, then use destroy(), but remove() is good for like.. If you glitch, and you want to play through it all again after resetting..



R$113,163 ~#Durst~ P̕͝-̕R-̷̀͟Ǫ̷-̶͘X-҉̶Y ( ͡° ͜ʖ ͡°)
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