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

Why does me teleporter script not do anything, yet it gives no error messages?

I have a teleporter script.

local r1 = script.Parent.Parent.ElevatorTopRegion.Reg1
local r2 = script.Parent.Parent.ElevatorTopRegion.Reg2
local r1p = r1.Position
local r2p = r2.Position

local region = Region3.new(Vector3.new(r1p.X,r1p.Y,r1p.Z), Vector3.new(r2p.X,r2p.Y,r2p.Z))

script.Parent.ClickDetector.MouseClick:Connect(function()
	local gete = game.Workspace:FindPartsInRegion3(region, nil, 1000)
	for i,v in pairs(gete) do
		print(v.Name)
		if v.Parent:FindFirstChild('Humanoid') then
			v.Parent.HumanoidRootPart.CFrame = CFrame.new(138.242, 128.559, 4.099)
		end
	end
end)

Nothing happens. It doesn't even print anything.

1 comment

0

Do print(unpack(gete)) and make sure it's not just an empty table.

1 answer

Is the script disabled? if not then add a wait() to the for loop

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