-----------------------


function warpPlayer(player, location)
	
	local HRP = player:WaitForChild("HumanoidRootPart")
	HRP.Position = Vector3.new(location.X, location.Y + 3, location.Z)
	
end

pad1.Touched:Connect(function(hit)
	
	if hit.Parent and hit.Parent:FindFirstChildOfClass("Humanoid").Health > 0 and bounce then
		
		bounce = false
		pad2.PointLight.Enabled = true
		warpPlayer(hit.Parent, pad2.Position)
		task.wait(1)
		bounce = true
		pad2.PointLight.Enabled = false
	end
	
end)

pad2.Touched:Connect(function(hit)

	if hit.Parent and hit.Parent:FindFirstChildOfClass("Humanoid").Health > 0 and bounce and padIsOneDirectional.Value == false then

		bounce = false
		pad1.PointLight.Enabled = true
		warpPlayer(hit.Parent, pad1.Position)
		task.wait(1)
		bounce = true
		pad1.PointLight.Enabled = false
	end

end)
