|
| 16 Jul 2012 04:23 PM |
-- Closes, It says somethings wrong with line 14 but I dont know what? sp = script.Parent spp = script.Parent.Parent
function onButtonClicked() spp.MorphOpener.Flasher.Disabled = true sp.Flasher.Disabled = true for i=0,1,.1 do wait(0.1) if sp.TextTransparency == -1 then print("Never") else sp.TextTransparency = i and sp.BackgroundTransparency = i and spp.MorphOpener.TextTransparency = i and spp.BackgroundTransparency = i end
script.Parent.MouseButton1Click:connect(onButtonClicked) |
|
|
| Report Abuse |
|
|
Flash77
|
  |
| Joined: 14 Jun 2008 |
| Total Posts: 550 |
|
|
| 16 Jul 2012 04:25 PM |
dont use ands that way sp.TextTransparency = i sp.BackgroundTransparency = i spp.MorphOpener.TextTransparency = i spp.BackgroundTransparency = i |
|
|
| Report Abuse |
|
|
killjoy37
|
  |
| Joined: 27 Aug 2008 |
| Total Posts: 2821 |
|
|
| 16 Jul 2012 04:28 PM |
You need to add two more end's, one for 'do' and one for 'if' I can tell you where to put them if you tell me this: if sp.TextTransparency equals -1 do you want either of these things happening,
sp.TextTransparency = i and sp.BackgroundTransparency = i and spp.MorphOpener.TextTransparency = i and spp.BackgroundTransparency = i
or only if sp.TextTransparency does not equal -1? |
|
|
| Report Abuse |
|
|
|
| 16 Jul 2012 04:31 PM |
| I want it to fade out using a for loop. |
|
|
| Report Abuse |
|
|
killjoy37
|
  |
| Joined: 27 Aug 2008 |
| Total Posts: 2821 |
|
| |
|
| |
|
killjoy37
|
  |
| Joined: 27 Aug 2008 |
| Total Posts: 2821 |
|
|
| 16 Jul 2012 07:30 PM |
Try this:
sp = script.Parent spp = sp.Parent
function onButtonClicked() spp.MorphOpener.Flasher.Disabled = true sp.Flasher.Disabled = true for i=0,1,.1 do wait(0.1) if sp.TextTransparency == -1 then print("Never") else sp.TextTransparency = i sp.BackgroundTransparency = i spp.MorphOpener.TextTransparency = i spp.BackgroundTransparency = i end end end
script.Parent.MouseButton1Click:connect(onButtonClicked) |
|
|
| Report Abuse |
|
|