Anthony Hopper, who was sleeping rough and selling drugs to fund his addiction, was snared in an undercover police operation