i couldnt do it
local part = game.Workspace.door
local part2 = game.Workspace.Part
local part3 = game.Workspace.Parte
local replica = game.Workspace.replic
part.touched:Connect(function(hit)
if hit.parent:FindFirstChild("Humanoid") then
wait(0.1)
local imrandom = math.random(1,2)
print(imrandom)
if imrandom == 1 then
local resetSeconds = 1
local isTouched = false
if not isTouched then
isTouched = true
end
wait(resetSeconds)
isTouched = false
local door = Instance.new("Part", workspace)
door.Transparency = replica.Transparency
door.Material = replica.Material
door.Position = part.Position
door.Size = replica.Size
else
for i = 0,1, .01 do
wait()
part.CFrame = part.CFrame:Lerp(part2.CFrame, i)
end
end
end
end)
help

1 comment
amazing whitespace