Cigarettes and alcohol harm those near them, but there are stiff regulations in place, there are social stigmas attached, and heavy legal consequences.
The legalization gives the government the funding to actually do something about it in proportion to demand.
We already have seen this during prohibition. It’s either regulate demand, or pretend that it can be banned and let a non government entity rise up and take power.