I’m scripting a loading screen so I want to know why the Interpolate function isn’t working properly like it’s supposed to. This script randomly chooses a point to cframe the camera to, then interpolates to point2 which is the endposition.
I tried adding point parts and placing them in workspace, but for some reason the table I collect from the points folder returns 0 when I use GetChildren().
I also locally did this to see if It would solve the issue and it did, however the positions werent accurate.
Here is my script (I didn’t add any of the variables, because I figured they aren’t necessary);
loader.OnClientEvent:Connect(function() local interpolation = false while wait() do if interpolation == false then interpolation = true cam.CameraType = "Scriptable" local radGroup = radTableGroup[math.random(1,#radTableGroup)] cam.CameraSubject = radGroup cam.CFrame = radGroup.CFrame cam.Focus = radGroup.CFrame + radGroup.CFrame.lookVector * 2 cam:Interpolate(radGroup.point2.CFrame ,radGroup.point2.CFrame + radGroup.CFrame.lookVector * 2,1) if frame.BackgroundTransparency ~= 1 then for i = 0,1,.01 do frame.BackgroundTransparency = i wait() end end cam.InterpolationFinished:Connect(function() wait(.5) for i = 1,0,-.01 do frame.BackgroundTransparency = i wait() end interpolation = false end) end end end)
The weird thing about this is that the script doesn’t position the parts correctly though they’re anchored, and cancollide false + positioned the way they’re supposed to.