Salinas23
|
  |
| Joined: 28 Dec 2008 |
| Total Posts: 37142 |
|
|
| 24 Aug 2013 11:49 PM |
brick = script.Parent Debounce = false name = brick.Parent unlocked = "Unlocked!"
brick.Touched:connect(function() if Debounce == false then Debounce = true end wait(2) brick.Color = BrickColor.new(26).Color brick.CanCollide = true for i = 180, 1, -1 do name.Name = ("Locked! Wait".. i.. " seconds to be unlocked!") wait(1) end brick.Color = BrickColor.new(208).Color name.Name = unlocked brick.CanCollide = false Debounce = false end)
Debounce does nothing in this case! I've tried with 'debounce' as well!
== DOOM BUCKET BEATS EVERY ITEM IN ROBLOX== |
|
|
| Report Abuse |
|
|
shonclub
|
  |
| Joined: 05 Sep 2009 |
| Total Posts: 1331 |
|
|
| 24 Aug 2013 11:53 PM |
| Is it the debounce that doesn't work or the script? |
|
|
| Report Abuse |
|
|
Salinas23
|
  |
| Joined: 28 Dec 2008 |
| Total Posts: 37142 |
|
|
| 24 Aug 2013 11:54 PM |
The debounce. The script works fine :)
== DOOM BUCKET BEATS EVERY ITEM IN ROBLOX== |
|
|
| Report Abuse |
|
|
|
| 24 Aug 2013 11:57 PM |
| maybe i read it wrong but i say a debounce in a if statment then you ending the if statment so no matter what the dbounce is it would still run the whole script |
|
|
| Report Abuse |
|
|
shonclub
|
  |
| Joined: 05 Sep 2009 |
| Total Posts: 1331 |
|
|
| 25 Aug 2013 12:00 AM |
You used db wrong.
brick = script.Parent Debounce = false name = brick.Parent unlocked = "Unlocked!"
brick.Touched:connect(function() if not Debounce then Debounce = true wait(2) brick.Color = BrickColor.new(26).Color brick.CanCollide = true for i = 180, 1, -1 do name.Name = ("Locked! Wait".. i.. " seconds to be unlocked!") wait(1) end brick.Color = BrickColor.new(208).Color name.Name = unlocked brick.CanCollide = false Debounce = false end end) |
|
|
| Report Abuse |
|
|
shonclub
|
  |
| Joined: 05 Sep 2009 |
| Total Posts: 1331 |
|
|
| 25 Aug 2013 12:01 AM |
| Notice, I didn't end the first 'if' statement. |
|
|
| Report Abuse |
|
|
Salinas23
|
  |
| Joined: 28 Dec 2008 |
| Total Posts: 37142 |
|
|
| 25 Aug 2013 12:05 AM |
@shon At first it does fine, but if I touch it again it goes crazy! qq
== DOOM BUCKET BEATS EVERY ITEM IN ROBLOX== |
|
|
| Report Abuse |
|
|
|
| 25 Aug 2013 12:13 AM |
Here,
brick = script.Parent Debounce = false name = brick.Parent unlocked = "Unlocked!"
brick.Touched:connect(function() if Debounce == true then return end Debounce = true end wait(2) brick.Color = BrickColor.new(26).Color brick.CanCollide = true for i = 180, 1, -1 do name.Name = ("Locked! Wait".. i.. " seconds to be unlocked!") wait(1) end brick.Color = BrickColor.new(208).Color name.Name = unlocked brick.CanCollide = false Debounce = false end) |
|
|
| Report Abuse |
|
|
|
| 25 Aug 2013 12:16 AM |
no wait,
brick = script.Parent Debounce = false name = brick.Parent unlocked = "Unlocked!"
brick.Touched:connect(function() if Debounce == true then return end Debounce = true wait(2) brick.Color = BrickColor.new(26).Color brick.CanCollide = true for i = 180, 1, -1 do name.Name = ("Locked! Wait".. i.. " seconds to be unlocked!") wait(1) end brick.Color = BrickColor.new(208).Color name.Name = unlocked brick.CanCollide = false Debounce = false end) |
|
|
| Report Abuse |
|
|
Salinas23
|
  |
| Joined: 28 Dec 2008 |
| Total Posts: 37142 |
|
|
| 25 Aug 2013 12:17 AM |
I fixed it for you, and, yet, nothing. omg
== DOOM BUCKET BEATS EVERY ITEM IN ROBLOX== |
|
|
| Report Abuse |
|
|