The few remaining residents of a Pennsylvania coal town that was largely razed in the 1980s because of an underground mine fire that still burns today have gotten their wish — to be left alone, free to live out their lives there.

A lengthy battle over eminent domain culminated this week when eight residents of Centralia settled their lawsuit against state officials who had been trying to evict them from their condemned homes. The settlement, notice of which was filed in U.S. District Court, allows the residents to stay for as long as they live. It also includes a cash payout of $349,500.

“Everybody got what we wanted, and everybody’s happy now,” resident Tom Hynoski, 52, said today.

The mine fire was ignited in 1962 and eventually spread to the vast network of mines beneath homes and businesses, threatening residents with poisonous gases and dangerous sinkholes. By the end of the 1980s, more than 1,000 people had moved and 500 structures had been demolished under a $42 million federal relocation program.

But some holdouts refused to go, even after their houses were seized in the early 1990s. They said the fire posed little danger to their part of town, accused government officials and mining companies of a plot to grab the rights to billions of dollars’ worth of anthracite coal, and vowed to stay put.

After years of letting them be, state officials decided a few years ago to take possession of the homes. The homeowners fought back with a federal lawsuit.

Hynoski, who has long contended that government corruption involving the coal rights was behind the state’s drive to force them out, claimed vindication.

“They bent us, but they didn’t break us,” he said.

State officials have long denied any such plot to grab the coal rights and say they sought possession of the properties out of public safety concerns.

Last year, a geologist with the Pennsylvania Department of Environmental Protection said the fire may have gone deeper underground but still poses a threat because it has the potential to open up new pathways for deadly gases to reach the remaining homes. But residents say that’s nonsense and point out that they’ve lived for decades in their homes without incident.

The agreement includes $218,000 to compensate residents for the value of their homes and $131,500 to settle additional claims raised in the lawsuit, according to Steve Kratz, spokesman for the state Department of Community and Economic Development, a defendant in the suit.

The mine fire has transformed Centralia into a macabre tourist attraction. There’s an intact street grid with almost nothing on it, clouds of steam waft from the cracked earth, and visitors gawk at the ruins of an abandoned highway.

But the homes that remain are neatly kept, and this week’s settlement means that Centralia as a town has not yet breathed its last.

“They get to live in their property and enjoy it the rest of their life,” said the plaintiffs’ attorney, Don Bailey. “We did very well.”