jmonster9
|
  |
| Joined: 03 Apr 2008 |
| Total Posts: 1685 |
|
|
| 16 Jul 2011 08:14 PM |
I need help with making Bricks Flash in code with one another. What is the best way to do that? Right now I'm trying to use a script that is infinite But, I need it to Stop when a button is clicked and Start again when a different button is clicked. Script-
while true do script.Parent.BrickColor = Bright yellow wait(1) script.Parent.BrickColor = Bright yellow wait(1) end
How do I make it both Infinate and Clickable While matching code with others The pattern is Yellow, Red, Yellow, Red Please help. |
|
|
| Report Abuse |
|
|
L2000
|
  |
| Joined: 03 Apr 2008 |
| Total Posts: 77448 |
|
|
| 16 Jul 2011 08:18 PM |
Make a function for when the stop button is clicked and when the start button is clicked.
Then, make this function change a certain value - True for when it's started, and false when it ended.
Finally, add this:
if Value and not InProgress then --Change Value to the Bool Value InProgress=true repeat script.Parent.BrickColor = Bright yellow wait(1) script.Parent.BrickColor = Bright yellow wait(1) until Value==false InProgress=false end |
|
|
| Report Abuse |
|
|
jmonster9
|
  |
| Joined: 03 Apr 2008 |
| Total Posts: 1685 |
|
|
| 16 Jul 2011 08:20 PM |
| Sorry I don't script a lot. Can you Explain that Simpler (I'm VERY Dumb in the Scripting world) |
|
|
| Report Abuse |
|
|
liger15
|
  |
| Joined: 23 Jul 2009 |
| Total Posts: 247 |
|
|
| 16 Jul 2011 08:23 PM |
onbutton = game.Workspace.On offbutton = game.Workspace.Off onbutton.ClickDetector.Clicked:connect(function() game.Workspace.Part.Script.Disabled = false end) offbutton.ClickDetector.Clicked:connect(function() game.Workspace.Part.Script.Disabled = true end) |
|
|
| Report Abuse |
|
|
jmonster9
|
  |
| Joined: 03 Apr 2008 |
| Total Posts: 1685 |
|
|
| 16 Jul 2011 08:25 PM |
| Sorry, I still don't under stand Can one of you guys send me a Message with some good detail. Sorry, I feel bad but I'm making it for my FreindI I REALLY don't want to let him down. |
|
|
| Report Abuse |
|
|
jmonster9
|
  |
| Joined: 03 Apr 2008 |
| Total Posts: 1685 |
|
|
| 16 Jul 2011 08:27 PM |
| *I fell bad for making you guys do this |
|
|
| Report Abuse |
|
|
liger15
|
  |
| Joined: 23 Jul 2009 |
| Total Posts: 247 |
|
|
| 16 Jul 2011 08:31 PM |
Here i made you a model with what you wanted
http://www.roblox.com/Model-item?id=56678647 |
|
|
| Report Abuse |
|
|