| |
|
| |
|
|
| 31 Aug 2013 11:49 PM |
CanCollide Transparency .Touched Look these things up in: wiki.roblox.com
If the wiki does not do it for you check a free model door. |
|
|
| Report Abuse |
|
|
| |
|
|
| 01 Sep 2013 12:06 AM |
Lua is pretty much as close to english as possible
qq he called me lawn |
|
|
| Report Abuse |
|
|
|
| 01 Sep 2013 12:12 AM |
If you don't know how scripting works in general then you will have a hard time grasping the idea of it at first, well at least I did.
So with that said, think of scripting as a file cabinet or a library. You must go through certain files to reach a certain page.
For example you have a file named "Food" and you want to get to "Cheese". In scripting it would be that exact sequence Food > Cheese. In Roblox the main "file" is called "game" you can basically access all things from it. Workspace is a child of "game" which means it's inside of it. To call Workspace you can say "game.Workspace" or just "workspace."
Essentially everything you see or interact with ingame is inside of "Workspace" so to call a certain brick you must say "game.Workspace.Brick"
CanCollide is a boolean so if you want to walk through a certain brick you must set it to false. Game.Workspace.CanCollide = false
For things like buttons you must create a touched event, the wiki has plenty of information about it. |
|
|
| Report Abuse |
|
|
|
| 01 Sep 2013 12:13 AM |
Fail
Game.Workspace.Brick.CanCollide = false |
|
|
| Report Abuse |
|
|
| |
|
|
| 01 Sep 2013 12:16 AM |
Here ya go. http://www.roblox.com/Door-item?id=128415523 |
|
|
| Report Abuse |
|
|
|
| 01 Sep 2013 12:17 AM |
Brick.CanCollide = false Brick.Transparency = 1
You can put as much in a function as you want
function yep() --script --nother script -anything wanted -herpaderp end
Just be sure to add ends when needed. |
|
|
| Report Abuse |
|
|
| |
|
|
| 01 Sep 2013 12:24 AM |
You have to understand that things like transparency, and cancollide are just properties of a brick. Think of it like a description. These are entirely differenty from functions, you can change as many properties as you want within a function.
brick = script.Parent --make sure you assign the brick variable to something, if it's "script.Parent" then make sure the script is inside the door.
function onTouch(part)
brick.Transparency=1 brick.CanCollide=false wait(3) brick.CanCollide-true brick.Transparency=0 end
brick.Touched:connect(onTouch)
|
|
|
| Report Abuse |
|
|
| |
|
|
| 01 Sep 2013 12:30 AM |
roblox.com/Forum/ShowPost.aspx?PostID=108855880
roblox.com/Forum/ShowPost.aspx?PostID=111754740
I've started to make some tutorials, check them out if you want. |
|
|
| Report Abuse |
|
|