Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
-1

How do u do so you click a door and then it open and closes each time you click? [closed]

Asked by 11 years ago

Put script in Awnser plz.

0
I mean by a swivel door so it swivels around! masterninjajm 0 — 11y

Closed as Not Constructive by evaera

This question has been closed because it is not constructive to others or the asker. Most commonly, questions that are requests with no attempt from the asker to solve their problem will fall into this category.

Why was this question closed?

2 answers

Log in to vote
1
Answered by
war8989 35
11 years ago

Here's a simple script that opens and closes when clicked. Insert the script and a ClickDetector into the door part. Modify the script to your liking. EDIT: I didn't see your comment, remove the CanCollide and Transparency lines and change them to rotate the door. Use this page on the wiki for help: http://wiki.roblox.com/index.php?title=CFrame

01door = script.Parent
02open = false
03 
04door.ClickDetector.MouseClick:connect(function()
05    if(open == false) then
06        door.CanCollide = false
07        door.Transparency = 0.5
08        open = true
09    elseif(open == true) then
10        door.CanCollide = true
11        door.Transparency = 0
12        open = false
13    end
14end)
0
Thanks thats perfect! masterninjajm 0 — 11y
0
You're welcome! war8989 35 — 11y
Ad
Log in to vote
0
Answered by 11 years ago

If you mean a sliding door then use the HansCo sliding door kit

http://web.roblox.com/HansCo-CFrame-Door-A-item?id=14704864

Its very simple to use. If you already have a door then the script might be usefull :P