Matthew Perry shares the devastating reality of filming Friends at the height of his opioid and alcohol addiction