|
| 25 Mar 2013 07:57 PM |
I'm a noob..
while true do wait(50) Script1.Parent.Transparency = 1 Script1.Parent.CanCollide = false wait(50) Script1.Parent.Transparency = 0 Script1.Parent.CanCollide = true end
|
|
|
| Report Abuse |
|
|
Solotaire
|
  |
| Joined: 30 Jul 2009 |
| Total Posts: 30356 |
|
|
| 25 Mar 2013 08:04 PM |
You don't have the path to "Script1" If "Script1" is the name of this script, simply use: script.Parent instead of Script1.Parent If it is not, then you can use any of the following: game.Workspace.Script1 workspace.Script1 Workspace.Script1 |
|
|
| Report Abuse |
|
|
|
| 25 Mar 2013 08:12 PM |
| Still didn't work when I put 'Script.Parent' is it because there is other scripts with the names 'Script'. |
|
|
| Report Abuse |
|
|
Solotaire
|
  |
| Joined: 30 Jul 2009 |
| Total Posts: 30356 |
|
|
| 25 Mar 2013 08:15 PM |
script.Parent, not Script.Parent Also, your wait time is set to 50. This value is in seconds. Try making it something such as wait(1) and try testing it. |
|
|
| Report Abuse |
|
|
|
| 25 Mar 2013 08:26 PM |
Script. with a S, affects it?
|
|
|
| Report Abuse |
|
|
|
| 25 Mar 2013 08:28 PM |
Lua is Case Sensitive so A will be different from a (unless they were set the same) A could be a brick a could be a number
|
|
|
| Report Abuse |
|
|
|
| 25 Mar 2013 08:29 PM |
Script could be a variable within the script. script is the actual script |
|
|
| Report Abuse |
|
|
|
| 25 Mar 2013 08:29 PM |
| Seriously? Fliippingg heck. |
|
|
| Report Abuse |
|
|
Solotaire
|
  |
| Joined: 30 Jul 2009 |
| Total Posts: 30356 |
|
|
| 25 Mar 2013 08:32 PM |
Yes. If you run it in Studio, you would get the following output: [Time] - Workspace.BasePlate.Script:3: attempt to index global 'Script' (a nil value)
Here is the working script: while wait(1) do script.Parent.Transparency = 1 script.Parent.CanCollide = false wait(1) script.Parent.Transparency = 0 script.Parent.CanCollide = true end
If you want to change it back to 50 inside of the waits, be my guest. The 1 is just for demonstrating purposes, and I assume this is going to be some kind of a door in which a wait of 1 would not be appropriate. |
|
|
| Report Abuse |
|
|
|
| 25 Mar 2013 08:32 PM |
| Yep...learned it many of times when I had the variable Do in the script...I put do and it would break because it was a different thing entirely... |
|
|
| Report Abuse |
|
|
|
| 25 Mar 2013 08:36 PM |
| Dang, you guys are helpful. |
|
|
| Report Abuse |
|
|