Up to now no one has helped me with this because every time I try it it is dead jittery and buggy, PLEASE help me move a models children (acting as a door.) SMOOTHLY like when you have 2 models the left door and the right door they move the opposite directions here is what I have so far. :)
local Model = script.Parent.D1
local Model2 = script.Parent.D2
function Move()
for Index,Part in pairs(Model:GetChildren()) do
if Part:IsA("BasePart") then
for i=1,20 do
Part.CFrame = Part.CFrame*CFrame.new(0,0,0.5)
wait()
end
wait()
end
for Index,Part in pairs(Model2:GetChildren()) do
if Part:IsA("BasePart") then
for i=1,20 do
Part.CFrame = Part.CFrame*CFrame.new(0,0,-0.5)
wait()
end
end
end
end
end
script.Parent.ClickDetector.MouseClick:connect(Move)

1 comment
How do I do it so I can move both?