Im trying to teleport the player when they click the button but it's not working any help?
code:
script.Parent.MouseButton1Click:Connect(function()
game.Players.LocalPlayer.Character.LowerTorso.CFrame = CFrame.new(workspace.Part.Position)
end)
Im trying to teleport the player when they click the button but it's not working any help?
code:
script.Parent.MouseButton1Click:Connect(function()
game.Players.LocalPlayer.Character.LowerTorso.CFrame = CFrame.new(workspace.Part.Position)
end)
I am certain that your script works:
script.Parent.MouseButton1Click:Connect(function()
game.Players.LocalPlayer.Character.LowerTorso.CFrame = CFrame.new(workspace.Part.Position)
end)
Please check if you are using a LocalScript which is under the textbutton since specified in the first line which isscript.Parent.MouseButton1Click:Connect(function()
And also check if your Using R15 specified in the 3rd line game.Players.LocalPlayer.Character.LowerTorso.CFrame whilst R15 having LowerTorso(s). And lastly, make sure your Part exists in the workspace!
Try to rename your part to a specify name.
script.Parent.MouseButton1Click:Connect(function()
game.Players.LocalPlayer.Character.LowerTorso.CFrame =
CFrame.new(game.Workspace.name.Position)
end)
I think that should work for you. Also, don`t forget to change line 3 name to a name with which you renamed your part.
mariofl2003 CFrame is not a valid member of model..??
this thread is marked as 'answered', and I see no accepted answer. Did you already found a way to fix it?
This discussion is preserved as it was. New answers, comments, and votes are closed.
1 comment
if u have multiple parts in workspace called part then it cant teleport you because there are multiple positions that it wants to teleport you to, make the part name something special