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

Help with teleport torso to part?

Asked by
FiredDusk 1466 Moderation Voter
8 years ago

Right when I touch the part to get tp'ed it waits like 2 secs to tp me.. I want it right away.

01Admins = {
02"Player1",
03}
04 
05script.Parent.Touched:connect(function(hit)
06    for i,v in pairs(Admins) do
07        if hit.Parent.Name == v then
08            hit.Parent:WaitForChild("Torso").CFrame = script.Parent.Parent.TpedTo.CFrame * CFrame.new(0,5,0)
09        end
10    end
11end)
0
add a wait() ? StoIid 364 — 8y

1 answer

Log in to vote
2
Answered by
StoIid 364 Moderation Voter
8 years ago

Try adding a wait() right under for i,v in pairs(Admins) do

1for i,v in pairs(Admins) do
2wait()
0
+2 rep :) FiredDusk 1466 — 8y
Ad

Answer this question