Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

How do I make a model move across the map smoothly with script?

I am currenctly using this script. It works perfectly smooth in roblox studio but half of it moves moves and after about 0.1 seconds, the other half joins it while in game. Causing it to have some kinda lag effect but I really isn't lagging. I tried using weld and glue but it is the same outcome. Please help me

while true do
	local Flight = game.Workspace.FlightModel
	Flight:SetPrimaryPartCFrame(Flight:GetPrimaryPartCFrame() * CFrame.new(0,0,-5))
	wait(.01)
end

1 answer

Try this:

model = [your model]

for move= 1,300,0.1 do


model.Position = Vector3.new(0,0,move)
wait(0.1)

end

Try this, I think the for loop shouldn’t lag

3 comments

0

which one is the z position

0

The last one. Tell me if it works! An accepted answer is greatly appreciated!

0

I changed the script!

This discussion is preserved as it was. New answers, comments, and votes are closed.