Late Friday Volkswagen agreed to pay its U.S. dealers $1.2 billion to compensate them for losses that occurred from the German automaker’s diesel fixing scandal.

Each of the 652 dealers will receive an average of $1.85 million over a period of 18 months, but they can choose to opt out of the settlement and pursue their own lawsuits against Volkswagen.

The exact amount of compensation awarded to each dealer depends on a number of factors, including the size of the dealer and the size of its market.

As part of the settlement, VW will continue making some incentive payments to dealers, buy back diesel vehicles that dealers can’t sell and suspend capital improvements for two years that it wanted dealers to make Automotive News reported.

The trade journal said that dealers were outraged over the emissions violations because of large investment they made in new, larger stores in hopes of seeing the company sell 800,000 vehicles a year, a goal set by former VW CEO Martin Winterkorn.

SEE ALSO: What Volkswagen’s ‘Dieselgate’ Is, and Why it Matters

A federal judge must still approve the settlement.

Volkswagen declined comment beyond a statement it issued Friday noting that the settlement “is not intended to apply to or affect Volkswagen’s obligations under the laws or regulations of any jurisdiction outside the United States.”

Volkswagen has been banned from selling diesel vehicles in the U.S. since late 2015, and won’t sell any diesel vehicles for the 2016 and 2017 model years.

U.S sales of VW vehicles have dropped 13 percent this year through August.

Last month VW said it was uncertain if it would ever sell diesel vehicles in the U.S. again.

The dealer settlement is separate from the earlier deal VW reached with U.S. vehicle owners who purchased 2.0-liter four-cylinder diesel vehicles.

That agreement calls for it spend up to $10 billion to either buy back or repair about 475,000 vehicles involved in the scandal.

SEE ALSO: New Cheating Software Discovered on Volkswagen Group 3.0-Liter Diesel Engines

It also includes more than $2.5 billion for unspecified environmental mitigation and an additional $2 billion to promote zero-emissions vehicles.

Still to be settled are the approximately 85,000 Volkswagens and Audis equipped with the more-powerful 3.0-liter engines that were caught up in the scandal.

VW has admitted it installed improper software that deactivated pollution controls on more than 11 million diesel vehicles sold worldwide.

Automotive News