This isnt working for some reason. Its in a local script inside the button
script.Parent.MouseButton1Down:connect(function() local localplayer = game.Players.LocalPlayer.Name print(localplayer) wait(1) localplayer.Torso.CFrame = CFrame.new(Vector3.new(1479.5, 10.7, -398)) end)
As kingdom5 said in his comment, you need to use the player's Character
rather than their Name.
script.Parent.MouseButton1Down:Connect(function() --use uppercase C Connect local char = game.Players.LocalPlayer.Character if not char then return --abort if they don't have a character end wait(1) chaar.HumanoidRootPart.CFrame = CFrame.new(1479.5, 10.7, -398) --^ use HumanoidRootPart instead of Torso ^ you don't have to use Vector3.new() end)