Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

I have script with CFrame, but how redo them to MoveTo?

Asked by 5 years ago

I want to redo this script to MoveTo, can anyone help? Becouse i dont know how do this... Script:

01local plr = game:service("Players").LocalPlayer
02local userinputservice = game:service("UserInputService")
03local chest = workspace.Chests.LargeChest
04_G.distance = 4
05userinputservice.InputBegan:connect(function(inp)
06   if inp.KeyCode == Enum.KeyCode.T then
07       while wait() do
08           for _,v in next, chest:GetChildren() do
09               v.HumanoidRootPart.CFrame = CFrame.new(plr.Character.HumanoidRootPart.CFrame.X,plr.Character.HumanoidRootPart.CFrame.Y,plr.Character.HumanoidRootPart.CFrame.Z - _G.distance)
10               v.HumanoidRootPart.Anchored = true
11           end
12       end
13   end
14end)

PS: Click view source to see all script, becouse website dont show to end!

0
plr.character:MoveTo()? (i might have got this wrong since im lazy at reading code) speedyfox66 237 — 5y
0
No, i need chest MoveTo local plr. How do this? Kalinka008 2 — 5y

Answer this question