WICHITA, Kan. (KSNW) — A standoff in south Wichita ended Monday afternoon when negotiators convinced a man in a moving truck to get out of the truck and then a police K-9 ran at the man and took him down to the ground.

The situation started around 8 a.m. when police say the man hopped a locked fence at a business at Broadway and Boston, broke a window and stole the keys to a truck. An employee in the business called 911.

Before the truck could get past the locked fence, police arrived. Officers say the man kept driving around the parking lot, acting like he was going to drive through the gates. At other times, he would park the vehicle.

A police spokesperson said police always try to use time and distance in situations like this. He said rushing into a situation can possibly lead to the use of force.

At one point, the KSN photojournalist on the scene saw officers give the person food and then back away. Police say they saw the man smoking during the negotiations. They believe it was possibly an illegal substance.

Police closed Broadway at Zimmerly during the standoff.

Also, nearby Hamilton Middle School was put on a “lockout.” A school district spokesperson said it means the exterior doors are locked, but inside activities are continuing as normal.

The KSN photojournalist at the scene heard police call the man by name. Police said they were able to identify him through pictures. They say he is someone who is known to law enforcement and that he recently stole a car and got into a car chase with sheriff’s office deputies.

The negotiator finally convinced the man to step out of the truck and the police dog moved in. Police say the suspect had minor injuries and was taken to a hospital for treatment before being taken to jail.