A wild yearling deer that wandered into a weedy lot in downtown Minneapolis on Sunday was shot and killed after a lengthy ordeal for police, witnesses and the deer itself.

Deemed a public safety threat, the animal was shot four times over the course of 30 to 45 minutes as Minneapolis police tried to put it down. The first two times it was shot, it would pop up and move around, police and witnesses said. The third shot knocked it down and the fourth shot killed it.

It took longer than expected because the officers had to wait for the deer to settle down before they could safely take another shot, explained a Minneapolis police spokeswoman.

“You just can’t start using a rifle in city limits and pow pow pow. You have to be careful on city surroundings,” said spokeswoman Cyndi Barrington.

Lonnie Solberg, building manager at the Sexton Lofts, said he found the deer about 3:30 p.m. in the vacant lot at 8th Street and Portland Avenue S. The weedy lot, ringed by a 7-foot security fence, shares a city block with the Lofts building.

Solberg, who said he didn’t know how the deer got there, said he thought the police did everything they could to prevent killing the animal. The officers searched for a tranquilizer gun but couldn’t get one quickly, he said. A police report on the incident shows the officers also contacted the Department of Natural Resources.

Concerned that the deer might jump into traffic, the police decided to kill it.

The injured deer at one time was running at the glass windows and sliding doors of the Sexton Lofts building, leaving a trail of blood drops on sidewalks along the building’s courtyard.

Later, the Animal Control Department picked up the deer’s body.