local Can = true
local Open = false
Button = script.Parent
function Click()
if Can then
Can = false
if Open == false then
local finish = script.Parent.Parent.PrimaryPart.CFrame*CFrame.Angles(0,math.rad(90),0)
for i = 0,1,.1 do
local cfm = script.Parent.Parent.PrimaryPart.CFrame:lerp(finish,i)
script.Parent:SetPrimaryPartCFrame(cfm)
wait()
end
end
Open = true
else
Open = false
local finish = script.Parent.Parent.PrimaryPart.CFrame*CFrame.Angles(0,math.rad(90),0)
for i = 0,1,.1 do
local cfm = script.Parent.Parent.PrimaryPart.CFrame:Lerp(finish,i)
script.Parent:SetPrimaryPartCFrame(cfm)
wait()
end
end
Can = true
end
COMMUNITY QUESTION
I don't know why the door is not open when i click?
0 answers
No public answers were preserved for this question.
This discussion is preserved as it was. New answers, comments, and votes are closed.

4 comments
https://www.roblox.com/library/4547650208/Fix-this-please
Lemme try something on your code.
I'm making a hole new model. I'll send you the link
Thank you.