|
| 19 Apr 2014 01:11 AM |
Why does the sound on this work for a while then suddenly all game sounds (Even like the normal roblox jumping sound) stops working
http://www.roblox.com/Code-Panel-item?id=154031975 (Thats the model)
Here is the script
local Colors = {"Bright blue", "Bright yellow"} local Code = "A1A3B4C3D4D2D1D3E3D3E3E5D5E5"
local Entered = "" local LastPanel = ""
for _, Panel in pairs (script.Parent.Panels:GetChildren()) do Panel.Touched:connect(function(Object) if Panel.Pressed.Value < #Colors and string.sub(Panel.Name, 7) ~= LastPanel and Object.Parent:FindFirstChild("Humanoid") then LastPanel = string.sub(Panel.Name, 7) Entered = Entered .. LastPanel Panel.Pressed.Value = Panel.Pressed.Value + 1 Panel.BrickColor = BrickColor.new(Colors[Panel.Pressed.Value]) script["Panel Sound"]:Play() end end) end
function Reset() for _, Panel in pairs (script.Parent.Panels:GetChildren()) do Panel.Pressed.Value = 0 Panel.BrickColor = BrickColor.new("Institutional white") end Entered = "" LastPanel = "" end
script.Parent.Buttons.Reset.Touched:connect(function(Object) if Object.Parent:FindFirstChild("Humanoid") then Reset() end end)
script.Parent.Buttons.Enter.Touched:connect(function(Object) if Object.Parent:FindFirstChild("Humanoid") then if Entered:lower() == Code:lower() then Reset() for _, Part in pairs (script.Parent.Door:GetChildren()) do Part.Transparency = 1 Part.CanCollide = false wait(2) Part.Transparency = 0.5 Part.CanCollide = true end end end end)
Other than the sound not playing after a while this script works fine, even after the sound cuts off. |
|
|
| Report Abuse |
|
|
| |
|
| |
|
| |
|
TxOreo1
|
  |
| Joined: 13 Apr 2014 |
| Total Posts: 34 |
|
|
| 19 Apr 2014 09:39 PM |
| What u mean? The sound stops entirely, or the sound sometimes cuts off as you move? |
|
|
| Report Abuse |
|
|
| |
|
TxOreo1
|
  |
| Joined: 13 Apr 2014 |
| Total Posts: 34 |
|
|
| 19 Apr 2014 09:42 PM |
More Qs(lol)
After it plays, or while playing?
If it is after playing, you can loop it. |
|
|
| Report Abuse |
|
|
|
| 20 Apr 2014 08:23 PM |
Its supposed to play when someone steps on the part It does that for a while then just stops, but the script gives no output and keeps working, other than the sound |
|
|
| Report Abuse |
|
|
tommyfun
|
  |
| Joined: 04 Jan 2011 |
| Total Posts: 1404 |
|
|
| 20 Apr 2014 08:25 PM |
| I think it's a Roblox bug, not the script. |
|
|
| Report Abuse |
|
|