Roblox Tween acting differently while in game

I have a snake that is controlled using a tween to move it around to different points, and there are limbs attatched using ball+socket joints to make it slither. It works while using the (F8) run feature in studio, however when I actually load in as a player into studio, this happens

using Run:

Script:

`local PrimaryPart = script.Parent.PrimaryPart

local Speed = 4

wait(5)

for i , node in ipairs(workspace.Nodes:GetChildren()) do

local TimeToNode = (PrimaryPart.Position - node.Position).Magnitude

local tween = game:GetService("TweenService"):Create(PrimaryPart, TweenInfo.new(TimeToNode/Speed,Enum.EasingStyle.Linear) , {CFrame = node.CFrame})

tween:Play()

tween.Completed:wait()

end'

FOR CONTEXT: The head is anchored, and the rest of the body is attatched using joints and attatchments and is unanchored.
image

Try inserting a npc that tricks it into thinking it’s a player and see if it happens in run mode, also press the </> button to put your code in

type or paste code here

That didn’t make it move, and it also made it freak out when it started moving and caused it to bunch up

using Play Solo:

It seems that the tween is being skipped, and the part is just teleporting to the next location.

Any help would be appreciated, thanks