The Wednesday shooting killed Terre Haute police Detective Greg Ferency, a 30-year department veteran and federal task force officer since 2010.

Paul Keenan, the special agent, said the suspect was shot by an FBI agent who was inside the office when he heard shots fired. The suspect then drove himself to the hospital, where he underwent surgery.

“The suspect showed up there before Detective Ferency came out of the building,” Kennan said. “That was the reason we used that word.”

For more reporting from the Associated Press, see below:

Investigators haven’t yet determined a motive for the ambush shooting of a police officer outside an FBI office in western Indiana, an FBI official said Thursday.

Keenan wouldn’t say whether Ferency knew the gunman or was targeted for some reason.

“We’re still looking at motive and we’re leaving all avenues open at this time,” Keenan said during a news conference in Terre Haute, about 70 miles (113 kilometers) west of Indianapolis.

Keenan said the filing of federal charges was “imminent” against the suspected gunman and that his identity wasn’t being released until then.

Dozens of police vehicles from multiple departments joined a procession past the Terre Haute police headquarters as a hearse carrying Ferency’s body was moved Wednesday evening to a hospital for an autopsy.

Terre Haute police Chief Shawn Keen said Ferency was the father of two adult children. Ferency’s police experience included work on drug and human trafficking investigations and providing violence risk assessments for churches.

“He was absolutely dedicated,” Keen said. “There’s not anything that he did that he didn’t put 110 percent into.”

Ferency is the third Terre Haute police officer fatally shot in the past decade. Officer Brent Long was killed in 2011 and Officer Robert Pitts died in 2018—both in shootings that happened as they and other officers were attempting to make arrests. Authorities determined both gunmen died from self-inflicted wounds.

Indiana Gov. Eric Holcomb called Ferency’s shooting “senseless.”

“Our heart breaks for Detective Greg Ferency’s family, loved ones and those who served with him every day protecting the residents of the Wabash Valley,” Holcomb said in a statement.