An armed man who walked into a Walmart store in Missouri dressed in body armor and fatigues and was detained at gunpoint by an off-duty firefighter is "lucky he's alive still" considering the situation he created, a police official said.

No shots were fired in the incident that happened just after 4 p.m. Thursday in Springfield, a city of around 160,000 in the southwestern part of the state, officials said.

The man who is said to be white and in his 20s was detained by the armed firefighter until police arrived at the Walmart Neighborhood Market, police said in a statement.

The man in body armor had been seen pushing a shopping cart and recording video of himself on a cellphone, police told NBC affiliate KYTV.

Police were called about a possible active shooter, and the store manager pulled a fire alarm and told people to evacuate, Springfield police Lt. Mike Lucas said.

"He walked in here, heavily armed with body armor on, in military fatigues, and caused a great amount of panic inside the store," Lucas said about the incident that came days after mass shootings at an El Paso Walmart and an Ohio entertainment district that left more than 30 people dead. "... Obviously, what's happened in Texas and Dayton and all that kind of stuff in the last seven days — that’s on everybody’s minds."

It was not clear what motivated the person in custody to enter the Springfield store.

The open carrying of firearms is legal in Missouri, as long as the weapon is not displayed in a threatening manner, according to the National Rifle Association’s website.

Though police did not name the person, police and online jail records indicate Dmitriy Andreychenko, 20, had been arrested.

The man entered the store with a tactical rifle, a handgun and more than 100 rounds of ammunition, KYTV reported, citing police. He was said to have been stopped by the armed firefighter after leaving through an emergency exit.