Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

CFrame only teleporting 1 person?? [Bug??]

I want this to teleport all players in the server to that position, but it only teleports 1 random person... any suggestions?

BTW: this does work, just doesnt teleport all , just 1 person at random ^

for n, Player in pairs(Players:GetPlayers()) do
        if Player.Character ~= nil and Player.Character:FindFirstChild("Humanoid") then
            Player.Character.HumanoidRootPart.CFrame = game.Workspace.Spawner.CFrame

1 answer

✓ Accepted answer
for i = 1,15 do
	for i,v in pairs(game.Players:GetPlayers()) do
		if v.Character and v.Character:FindFirstChildOfClass("Humanoid") then
			pcall(function()
			v.Character:MoveTo(workspace.Spawner.Position)
			end)
		end
	end
	wait()
end

1 comment

0

Why are you teleporting all players 15 times?

This discussion is preserved as it was. New answers, comments, and votes are closed.