With a plea agreement announced by county prosecutors Jan. 21, the case of Jereme Lee Nelson — once charged with capital murder — is all but complete.

Prosecutors and Nelson's defense team put together a plea agreement Jan. 10 that resulted in a guilty plea and nearly 40 years of prison time. Prosecutors met with the families of Nelson's three victims before finalizing the deal or announcing it to media.

Formal sentencing is still to come.

The deal stipulates that capital murder charges — which could result in the death penalty — be reduced to a lesser charge of intentional second-degree murder. Nelson also pleaded to second-degree murder, voluntary manslaughter and aggravated burglary, all felonies. Nelson pleaded guilty to all charges.

The agreement requests a sentence of 39 years in prison. Nelson turned 39 in December.

"This was a case that if we could get a substantial prison sentence, whereby Nelson would be serving most of the rest of his life behind bars, this was something we should look at," said David Yoder, Harvey County attorney. "Nothing can bring back the three victims. ... Both decided that rather than take their chances at trial, this was a resolution everyone can live with."

One of the witnesses to the crime died last year, while the other testified in a deposition that while at the scene they were looking down trying to get a car started while everything was going on and did not see everything that happened.

"The only other person alive that was at the scene was Nelson, and he did not make any statements," Yoder said. "It came down to proof of premeditation. I don't think there is any doubt to the killings, there is just how it all occurred at the scene and being able to reconstruct it."

Both Nelson and 31-year-old Myrta Rangel were arrested Jan. 12, 2017, near Rosarito, Mexico, by Mexican authorities on warrants connected to homicides that occurred Oct. 30, 2016.

According to the Kansas Bureau of Investigation, Travis Street, 33, of Moundridge; Angela May Graevs, 37, of Moundridge; and Richard Prouty, 52, of Newton, were found dead in a driveway in the 8600 block of Spring Lake Road near Alta Mills — between Hesston and Moundridge — on Oct. 30, 2016.

At 5:30 p.m. that day, a motorist called 911 and said she had been waved down by a maroon vehicle. She told dispatchers she had been told there were two bodies in the driveway of a home in the 8600 block of N. Spring Lake Road.

"This was basically a drug deal gone bad," Yoder said. "There is no secret to the fact that Travis Street was heavily involved in methamphetamine trafficking because that was the whole reason he and Jereme Nelson were working together and associated with each other. They were having a territorial dispute."

According to the sheriff’s department, investigators found three bodies in the driveway and an 18-month-old baby in the house. Then sheriff T. Walton said the deaths had happened “earlier in the day,” estimating a time of death of about 11 a.m.

He said he believed the shootings took place outside the house. The child’s parents were among the victims of the shooting. The child was taken to other family for care.

Rangel later pleaded guilty to transferring a firearm she knew would be used to commit a drug trafficking crime and to giving a firearm to a convicted felon.