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

Why won't this code work?

I'm trying to make 'Jericho1' move smoothly to a position, but when I use the code below it jumps to the last digit.

for i = 1, 50 do
   Jericho1:SetPrimaryPartCFrame(CFrame.new(-31.209-i, 3.451, -126.11))
end

Could someone please tell me what's wrong and/or what I need to do to fix this?

Thanks.

1 comment

0

Please make your title relevant to your question.

1 answer

✓ Accepted answer

The code itself is fine, although you forgot to add a wait. It should be:

for i = 1, 50 do Jericho1:SetPrimaryPartCFrame(CFrame.new(-31.209-i, 3.451, -126.11)) wait() end

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