This explains drug-seeking. But it doesn't explain addiction. It makes perfect sense for evolution to develop emotional rewards as a spur to adaptive behaviors. It's understandable that there might be substances scattered about in nature that leapfrog life experience and go straight to our brain's reward system. Consider Antechinus stuartii , the Australian marsupial mouse.
Antechinus males live a celibate life for about a year.
Then they mate. They usually die within days of that probably thrilling event. Ah, that's it. Anything so good as to inspire repetitive behavior to the point of risking our all is likely to signal to the brain that we are doing the exact right thing for gene perpetuation. There are drugs that set up a regenerating cycle.