Each Pennsylvania county is expected to receive part of a $1 billion settlement for drug treatment and prevention, in a deal with four companies negotiated by Pennsylvania Attorney General Josh Shapiro and other state attorneys general.

Despite criticism of the settlement, Philadelphia joined the agreement just ahead of a midnight deadline on Wednesday and will receive at least $186 million out of the deal.

Mayor Jim Kenney and District Attorney Larry Krasner had argued the settlement from the companies was too low and the 18-year payout schedule too long. But the city ultimately agreed to take part, while Krasner opted not to do so, and will keep pursuing a lawsuit.

» READ MORE: Philadelphia has joined a $1 billion opioid settlement with every county in Pa., AG says

Counties are slated to receive funding as soon as April. The allocation formula guaranteed at least $1 million to every county that signed on.

Here’s the estimated amount of money that each Pennsylvania county will receive from the settlement, according to Shapiro’s office:

Adams County
Allegheny County
Armstrong County
Beaver County
Bedford County
Berks County
Blair County
Bradford County
Bucks County
Butler County
Cambria County
Cameron County
Carbon County
Centre County
Chester County
Clarion County
Clearfield County
Clinton County
Columbia County
Crawford County
Cumberland County
Dauphin County
Delaware County
Elk County
Erie County
Fayette County
Forest County
Franklin County
Fulton County
Greene County
Huntingdon County
Indiana County
Jefferson County
Juniata County
Lackawanna County
Lancaster County
Lawrence County
Lebanon County
Lehigh County
Luzerne County
Lycoming County
McKean County
Mercer County
Mifflin County
Monroe County
Montgomery County
Montour County
Northampton County
Northumberland County
Perry County
Philadelphia County
Pike County
Potter County
Schuylkill County
Snyder County
Somerset County
Sullivan County
Susquehanna County
Tioga County
Union County
Venango County
Warren County
Washington County
Wayne County
Westmoreland County
Wyoming County
York County

*Denotes counties that will receive an additional share of a $30 million pool for their work on opioid litigation. The three counties receiving a portion of that funding are Carbon, Delaware, and Philadelphia. Philadelphia’s portion of $13 million is already incorporated into its final total of $186 million listed above.