blob4587
|
  |
| Joined: 27 Oct 2012 |
| Total Posts: 126 |
|
|
| 27 Mar 2014 11:26 PM |
So, I"m a horrible scripter. But how do I make a brick's transparency go to one, and then to zero, and it keeps going.
Is it something like this?
local function blink() Game.Workspace.Part.Transpaarency = 1 wait(0.5) Game.Workspace.Part.Transpaarency = 0 wait(0.5) Game.Workspace.Part.Transpaarency = 1 end
blink()
Thanks for your time. |
|
|
| Report Abuse |
|
|
Zeloi
|
  |
| Joined: 27 Sep 2010 |
| Total Posts: 1143 |
|
|
| 27 Mar 2014 11:27 PM |
while wait(0.5) do game.Workspace.Part.Transparency = 1 wait(0.5) game.Workspace.Part.Transparency = 0 end |
|
|
| Report Abuse |
|
|
maxomega3
|
  |
| Joined: 11 Jun 2010 |
| Total Posts: 10668 |
|
|
| 27 Mar 2014 11:28 PM |
| Put it into a while loop if you want it to go on forever. There's only one "a" in "Transparency" as well. Other than that, it looks good. |
|
|
| Report Abuse |
|
|
blob4587
|
  |
| Joined: 27 Oct 2012 |
| Total Posts: 126 |
|
| |
|
Zeloi
|
  |
| Joined: 27 Sep 2010 |
| Total Posts: 1143 |
|
|
| 27 Mar 2014 11:29 PM |
| max theres 2 a's in Transparency |
|
|
| Report Abuse |
|
|
GOLDC3PO
|
  |
| Joined: 31 May 2011 |
| Total Posts: 509 |
|
|
| 27 Mar 2014 11:29 PM |
local function blink(part) part.Transparency = 0 for i=1, 1000 do part.Transparency = part.Transparency + 0.001 end for i=1, 1000 do part.Transparency = part.Transparency - 0.001 end end blink(game.Workspace.Part) |
|
|
| Report Abuse |
|
|
transIate
|
  |
| Joined: 20 Jun 2013 |
| Total Posts: 2699 |
|
|
| 27 Mar 2014 11:30 PM |
while wait''do workspace.Part.Transparency=1; else workspace.Part.Transparency=0; end |
|
|
| Report Abuse |
|
|
maxomega3
|
  |
| Joined: 11 Jun 2010 |
| Total Posts: 10668 |
|
|
| 27 Mar 2014 11:30 PM |
mb LOL
There's two a's. Just not in a row. |
|
|
| Report Abuse |
|
|
GOLDC3PO
|
  |
| Joined: 31 May 2011 |
| Total Posts: 509 |
|
|
| 27 Mar 2014 11:30 PM |
local function blink(part) part.Transparency = 0 for i=1, 1000 do part.Transparency = part.Transparency + 0.001 wait(0.001) end for i=1, 1000 do part.Transparency = part.Transparency - 0.001 wait(0.001) end end blink(game.Workspace.Part) |
|
|
| Report Abuse |
|
|
Zeloi
|
  |
| Joined: 27 Sep 2010 |
| Total Posts: 1143 |
|
| |
|
transIate
|
  |
| Joined: 20 Jun 2013 |
| Total Posts: 2699 |
|
| |
|
GOLDC3PO
|
  |
| Joined: 31 May 2011 |
| Total Posts: 509 |
|
|
| 27 Mar 2014 11:34 PM |
| He wants a function not a loop. |
|
|
| Report Abuse |
|
|
blob4587
|
  |
| Joined: 27 Oct 2012 |
| Total Posts: 126 |
|
|
| 27 Mar 2014 11:37 PM |
| Whoa, I got way more feedback than I expected to get, thanks for all your help! |
|
|
| Report Abuse |
|
|
|
| 27 Mar 2014 11:37 PM |
gold, you cant do a wait() smaller than .03
so wait(0.0001) would not work |
|
|
| Report Abuse |
|
|
maxomega3
|
  |
| Joined: 11 Jun 2010 |
| Total Posts: 10668 |
|
| |
|
GOLDC3PO
|
  |
| Joined: 31 May 2011 |
| Total Posts: 509 |
|
|
| 27 Mar 2014 11:39 PM |
@thed 0.3 is just the default for wait(), you can wait anything. |
|
|
| Report Abuse |
|
|
| |
|
cntkillme
|
  |
| Joined: 07 Apr 2008 |
| Total Posts: 44956 |
|
|
| 28 Mar 2014 12:21 AM |
| You can't wait anything, the lower you can wait is ~1/60 |
|
|
| Report Abuse |
|
|
|
| 28 Mar 2014 12:28 AM |
part = game.Workspace.BrickName -- add more part lines for more blinkidys! while true do function blinkidy() part.Transparency = 0 wait(0.5) part.Transparency = 1 blinkidy() end end
--Lol thats just a fun way the function and 1 end isnt needed :D |
|
|
| Report Abuse |
|
|
cntkillme
|
  |
| Joined: 07 Apr 2008 |
| Total Posts: 44956 |
|
|
| 28 Mar 2014 12:40 AM |
| You could get ride of the while loop Mc |
|
|
| Report Abuse |
|
|
|
| 28 Mar 2014 12:48 AM |
| I know that, its just for fun. |
|
|
| Report Abuse |
|
|
|
| 28 Mar 2014 01:55 AM |
function who(thing) repeat thing.Transparency = thing.Transparency - math.random(-1,1)/10 wait() until thing == nil end
who(Workspace.Part)
|
|
|
| Report Abuse |
|
|
GOLDC3PO
|
  |
| Joined: 31 May 2011 |
| Total Posts: 509 |
|
|
| 28 Mar 2014 04:18 AM |
@mc You put the loop in the wrong place. |
|
|
| Report Abuse |
|
|
|
| 28 Mar 2014 11:19 AM |
| Look gold, that doesnt matter. |
|
|
| Report Abuse |
|
|