Hi,
My goal is to make a straight conveyor belt which spawns a model and moves the model along the belt as smooth as possible from point A to point B. The idea would be to do this on the server or to where it is visible by all players in the server.
As far as I am aware, there are multiple ways of moving a part from point A to point B smoothly (tweens, lerping, heartbeats, etc.), but what are most games doing?
Currently, I am doing it with a heartbeat and just modifying the CFrame on every iteration, but this does not look good and isnāt matching my gameās frame rate smoothly when testing in a public server. Here is what I currently have:
task.spawn(function()
ConnectionModule:Connect(boxClone, RunService.Heartbeat, function(deltaTime: number)
local primaryPart: Part = boxClone.PrimaryPart
primaryPart.CFrame = primaryPart.CFrame + start.CFrame.LookVector * self.ConveyorSpeed * deltaTime
end)
end)
Any insight is greatly appreciated, thanks!