I think this is a pretty good approach actually. Give people the freedom to gamble, but discourage it through taxes. It's best to tax things you want to discourage. So it's preferable to tax gambling rather than productive economic activity.
Related concept: https://en.wikipedia.org/wiki/Pigouvian_tax
Gambling is an addiction without physical substance, it is not clear if taxes reduce gambling.
Taxing the dopamine thing does not discourage the doing of the dopamine thing. Just penalizes the addict and worsens their position.
This meta-analysis apparently found that alcohol taxes were effective for reducing alcohol consumption:
https://pmc.ncbi.nlm.nih.gov/articles/PMC3735171/
Why should gambling be different?