-- I want a more efficient method of sorting the destinations.


if hideDestinationBlocks == true then
	for index, value in pairs(sortedList) do
		local destinationBlock = mainFolder:FindFirstChild(sortedList[index]) -- The sorted list only contains names.
		destinationBlock:ClearAllChildren()
		destinationBlock.Transparency = 1
	end
end

alignPosition.MaxVelocity = topSpeed
platform.Anchored = false

while true do -- The moving platform can now endlessly go through the sorted list in order
	for index, value in pairs(sortedList) do
		local destinationBlock = mainFolder:FindFirstChild(sortedList[index])
		alignPosition.Position = destinationBlock.Position
		wait(moveDelay)
	end
end
