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: Local Scripts, Regular Scripts, Remote Event.

Previous Thread :: Next Thread 
Exquisites is not online. Exquisites
Joined: 06 Apr 2014
Total Posts: 2732
17 Feb 2015 08:48 PM
The whole Purpose to these scripts is to:
1. Remove All Sounds.
2. Playing a sound once all aren't playing (RemoteEvent)

Regular Script:
local sounds = {"206507745","167673832",""}

game.Workspace.ChangeSound.OnServerEvent:connect(function(plr, soundNum)
if script:FindFirstChild("Sound") then
script.Sound:Remove()
end
local sound = Instance.new("Sound", script)
sound.SoundId = sounds[soundNum]
sound:Play()
end)

Local Script:

for i, v in pairs(script.Parent:GetChildren()) do
v.MouseButton1Click:connect(function(click)
game.Workspace.ChangeSound:FireServer(v.Sound.Value)
end)
end

SadForMySad
Report Abuse
Exquisites is not online. Exquisites
Joined: 06 Apr 2014
Total Posts: 2732
17 Feb 2015 08:51 PM
Local Script is in the Frame of the Surface Gui BTW.

SadForMySad
Report Abuse
chimmihc is not online. chimmihc
Joined: 01 Sep 2014
Total Posts: 17143
17 Feb 2015 08:52 PM
where is the surface gui?
Report Abuse
Exquisites is not online. Exquisites
Joined: 06 Apr 2014
Total Posts: 2732
17 Feb 2015 08:53 PM
Part1.SurfaceGui, the surface GUI is named "Sound Board"

SadForMySad
Report Abuse
chimmihc is not online. chimmihc
Joined: 01 Sep 2014
Total Posts: 17143
17 Feb 2015 08:54 PM
place it in starter gui and makes its adornee to the part
Report Abuse
Exquisites is not online. Exquisites
Joined: 06 Apr 2014
Total Posts: 2732
17 Feb 2015 08:56 PM
Alright.

SadForMySad
Report Abuse
Exquisites is not online. Exquisites
Joined: 06 Apr 2014
Total Posts: 2732
17 Feb 2015 08:57 PM
I don't understand, I have a Part with a click detector that makes the GUI Visible on Part1

SadForMySad
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