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

Help with teleport script?(Not teleporting)

Asked by 6 years ago

I am trying to make all the players teleport to one place in the map but it won't work.

teleport() = function
       game.Workspace.players.Vector3 = Vector3.new(0,0,0)
end
teleport()

1 answer

Log in to vote
0
Answered by 6 years ago
pos = Vector3.new(0,0,0) -- Moves the player to the position
teleport = function()
    for i,player in pairs(game.Players:GetPlayers()) do
        if player.Character then
            player.Character:MoveTo(pos))
        end
    end
end
wait()
teleport ()
0
thx Prbo1201 56 — 6y
Ad

Answer this question