Montpelier — Vermont will see a $28 million windfall after the state Attorney General’s Office settled 14 years of legal disputes with the tobacco industry.

In announcing the settlement deal on Thursday, officials said $14 million will go toward the state’s ongoing efforts to combat the opioid-addiction crisis.

The other $14 million is up for grabs. And it arrives at a fortuitous time, as lawmakers are working through the details of the state’s fiscal year 2019 budget, which includes some potentially painful cuts.

“We all have different ideas of what to do with the money,” Gov. Phil Scott said. “I can just say, from my standpoint, we’ll work together in order to come to some conclusion that gives the most benefit to Vermonters and gives the highest rate of return.”

Vermont is one of 46 states that receives annual payments from the tobacco industry as part of a “master settlement agreement” inked in 1998. That deal resolved lawsuits filed by states over the health effects of smoking, and the settlement was signed “in order to further the settling states’ policies designed to reduce youth smoking, to promote the public health and to secure monetary payments.”

In fiscal year 2017, Vermont received nearly $34.8 million from the master settlement agreement. That money was divided among the Agency of Human Services, the Department of Health, the Attorney General’s Office, the Agency of Education, the Department of Liquor Control and the Judiciary.

Each year, the majority of Vermont’s tobacco money is allocated to Agency of Human Services’ “global commitment” budget in order to draw down matching federal funds for health initiatives and other issues.

The money announced on Thursday, however, is separate from that annual allocation.

Instead, it has to do with a complex mechanism by which a state’s yearly settlement payment risks being reduced unless that state can show in arbitration that it “diligently enforced” tobacco laws against cigarette manufacturers that didn’t sign the 1998 agreement.

There’s a lot of money at stake for states in those deliberations, which can be protracted and costly. But Vermont officials now say they have settled 14 years of arbitration disputes, resulting in an additional payment of $28 million from the tobacco companies.

Theoretically, Vermont could have gotten millions more by fighting over and winning adjustment disputes for each year. But state Treasurer Beth Pearce said she reviewed the attorney general’s settlement and found it satisfactory.

“We think it’s the best possible deal for the state and in the taxpayers’ interest today,” Pearce said. “When you talk about money, a dollar in the present is worth more than a dollar in the future because of inflation and the interest rates.”

State officials have decided that half of the settlement will be earmarked for opiate-related initiatives. Given the source of the money, that’s fitting, Attorney General TJ Donovan said.

“When you look at the master settlement agreement in 1998 … that was to address the biggest public health issue that was facing our country at that time,” Donovan said. “I think we could say that, in Vermont and across this country, the biggest public health issue today is the opiate crisis.”

It’s not yet clear what addiction initiatives the state will prioritize. Scott said he will seek guidance from his Opioid Coordination Council and will focus on prevention, treatment, recovery and enforcement.