Basically, it's designed to make a door transparent and cancollide=false on click, then when it's clicked again, it goes cancollide = true and transparency = 0. Except that doesn't happen? You click a button for it to work, which is a part. The model, which is the door (model because it has multiple parts) is inside the button. The model is called yolo.
local hi = true
function on()
hi = true
local found = script.Parent.yolo:GetChildren()for i = 1, #found do i.Transparency = 0 end
local found = script.Parent.yolo:GetChildren() for i = 1, #found do i.CanCollide = true end end
function off()
end
hi = false
local found = script.Parent.yolo:GetChildren( )for i = 1, #found do i.Transparency = 0.5 end
local found = script.Parent.yolo:GetChildren() for i = 1, #found do i.CanCollide = false end
function onClicked()
if hi == true then off() else on() end
end
script.Parent.ClickDetector.MouseClick:connect(onClicked)
on()
