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

Do you think this teleport script is going to work or is it valid?

Asked by 7 years ago

Hi I was making a racing game on ROBLOX. Is the following teleport script valid or at least work? I was not too sure if it was going to work? It needs to be R6 and R15 capable.

Script:

01function teleportPlayers(target)
02    for _, player in pairs(game.Players:GetChildren())do
03        while player.Character == nil do
04            wait()
05        end
06        local character = player.Character
07        local torso = character:WaitForChild("UpperTorso")or("Torso")
08        torso.CFrame = target.CFrame
09    end
10end
0
no hiimgoodpack 2009 — 7y

2 answers

Log in to vote
0
Answered by
YTGonzo 20
7 years ago

**This script should work fine. **

Ad
Log in to vote
0
Answered by 7 years ago

don't use torsos trust me it's a lot better to use HumanoidRootPart because everything is attached to it so it's better to use that.

Answer this question