of     1   

cjsaurusrex
#41652245Friday, January 28, 2011 3:31 PM GMT

Heya, My script to open the door worked but because I made it lower the transparency every 0.1 second if you kept clicking the button it would repeat that so I added a IntValue but now I cant get my script to work at all. Can someone help? Doorv = script.Parent.Parent.DoorV function myfunction() if Doorv value == "1" then script.Parent.Parent.Door.Transparency = 0 wait(0.1) script.Parent.Parent.Door.Transparency = 0.1 wait(0.1) script.Parent.Parent.Door.Transparency = 0.3 wait(0.1) script.Parent.Parent.Door.Transparency = 0.5 wait(0.1) script.Parent.Parent.Door.Transparency = 0.7 script.Parent.Parent.Door.CanCollide = false Doorv.Value = "0" end script.Parent.ClickDetector.MouseClick:connect(myfunction)
dino2306
#41652289Friday, January 28, 2011 3:34 PM GMT

line 2 : doorv value (No dot And lower cased first letter V)
dino2306
#41652308Friday, January 28, 2011 3:34 PM GMT

Oh and remove the "" those make a string , its also bugging you can input numbers as a number (like IntValue.Value = 1)
DangCool
#41652309Friday, January 28, 2011 3:35 PM GMT

[ Content Deleted ]
DangCool
#41652311Friday, January 28, 2011 3:35 PM GMT

[ Content Deleted ]
xXxXxdragonxXxXx
Top 100 Poster
#41652340Friday, January 28, 2011 3:36 PM GMT

Doorv = script.Parent.Parent.DoorV function myfunction() if Doorv.Value == "1" then for i = 0, 1, 0.1 do Doorv.Transparency = i wait() end script.Parent.Parent.Door.CanCollide = false wait(2) for i = 0, 1, 0.1 do Doorv.Transparency = Doorv.Transparency - 0.1 wait() end Doorv.Value = "0" end end
dino2306
#41652354Friday, January 28, 2011 3:37 PM GMT

@Dragon it works now? if not , remove the "" between the numbers
DangCool
#41652377Friday, January 28, 2011 3:38 PM GMT

[ Content Deleted ]
xXxXxdragonxXxXx
Top 100 Poster
#41652381Friday, January 28, 2011 3:38 PM GMT

Doorv = script.Parent.Parent.DoorV function myfunction() if Doorv.Value == 1 then for i = 0, 1, 0.1 do Doorv.Transparency = i wait() end script.Parent.Parent.Door.CanCollide = false wait(2) for i = 0, 1, 0.1 do Doorv.Transparency = Doorv.Transparency - 0.1 wait() end Doorv.Value = 0 script.Parent.Parent.Door.CanCollide = true end end
xXxXxdragonxXxXx
Top 100 Poster
#41652391Friday, January 28, 2011 3:39 PM GMT

@Dang ewp.
xXxXxdragonxXxXx
Top 100 Poster
#41652410Friday, January 28, 2011 3:39 PM GMT

@Dang No... I already HAD the end. Look up on it.
DangCool
#41652422Friday, January 28, 2011 3:40 PM GMT

[ Content Deleted ]
DangCool
#41652431Friday, January 28, 2011 3:40 PM GMT

[ Content Deleted ]
cjsaurusrex
#41652477Friday, January 28, 2011 3:42 PM GMT

Ok thanks but can someone explain to me how "for i = 0, 1, 0.1 do Doorv.Transparency = i " works as I want to also use this type of script for my close button and I need to know how to edit. and would I change the "0.1" to "0.7" if I want it to be 0.7 transparency at the end?
xXxXxdragonxXxXx
Top 100 Poster
#41652516Friday, January 28, 2011 3:44 PM GMT

@Cj No. 0.1 is increasing as that much, So I did it .5 time, as 0, 0.5, 0.1 Then the brick will increase the transparency of 0.1 by 5 time, then it'll be half transparent. You can change 0, 1, 0.1 to 0, 0.7, 0.1 if you want to.
cjsaurusrex
#41652582Friday, January 28, 2011 3:47 PM GMT

and how would I do that method to make the door go down to 0 transparency? would it go "0.7, 0.7, 0.1"
xXxXxdragonxXxXx
Top 100 Poster
#41652596Friday, January 28, 2011 3:48 PM GMT

Doorv = script.Parent.Parent.DoorV function myfunction() if Doorv.Value == 1 then for i = 0, 0.7, 0.1 do Doorv.Transparency = i wait() end script.Parent.Parent.Door.CanCollide = false wait(2) for i = 0, 0.7, 0.1 do Doorv.Transparency = Doorv.Transparency - 0.1 wait() end Doorv.Value = 0 script.Parent.Parent.Door.CanCollide = true end end That should solve the problem.
cjsaurusrex
#41652686Friday, January 28, 2011 3:53 PM GMT

I put the script it and the only bit working is the changing of CanCollide as it wont change the transparency...

    of     1