A Burnsville man has pleaded guilty to fatally shooting a man in a parked vehicle in south Minneapolis and leaving the unintended target to die in the arms of a friend.

When Reginald Myers Jr., 35, is sentenced for the Feb. 23, 2014 murder of Adrian Carr, 35, of St. Louis Park, he is expected to receive 27 years in prison as part of an agreement in which prosecutors dropped the first-degree murder indictment, Hennepin County Attorney Mike Freeman said in announcing Monday’s guilty plea.

“This is a very good outcome,” Freeman said. “Unfortunately, more work needs to be done on the front end to reduce these deadly shootings, especially of innocent people like Adrian Carr.”

Myers admitted in court that he was a passenger in a car driven by Shane McPike, of Hopkins. They saw Carr and another man in the 3400 block of Snelling Avenue and came back around because they thought Carr was someone they had once clashed with.

It turned out that Carr was simply removing some items from his SUV. As McPike drove north on Snelling, Myers fired at least six shots into Carr’s SUV. One of the bullets fatally struck Carr in the head.

Myers admitted that he and McPike mistakenly thought Carr was the man they were after.

Police said that when officers arrived at the scene, they saw the friend in the back seat of the SUV holding Carr’s bleeding head. The friend said the shots came from a man in the front passenger seat of McPike’s car.

Police searched McPike’s car and recovered a handgun inside a sock. Shell casings at the scene were consistent with the caliber of that gun.

McPike, 36, has pleaded guilty to aiding an offender and being a felon in possession of a firearm. In 2006, McPike was convicted of a felony-level drug offense, making it illegal for him to possess a gun.

Myers is scheduled to be sentenced on July 24.