Adds a delay to the loop