HASLET, Texas — Acrid gun smoke clouded the sunny entrance of a Texas church on a recent Sunday.

Seven men wearing heavy vests and carrying pistols loaded with blanks ran toward the sound of the shots, stopping at the end of a long hallway. As one peeked into the foyer, the “bad guy” raised the muzzle of an AR-15, took aim and squeezed the trigger.

The simulated gunfight at the church in Haslet was part of a niche industry that trains civilians to protect their churches using the techniques and equipment of law enforcement. Rather than a bullet, the rifle fired a laser that hit Stephen Hatherley’s vest — triggering an electric shock the 60-year-old Navy veteran later described as a “tingle.”

The shootings this month killed more than 30 people at an El Paso Walmart and Dayton, Ohio, entertainment district. But gunmen have also targeted houses of worships in recent years, including a church in rural Sutherland Springs, Texas, where more than two dozen people were shot dead in 2017.

The anxiety of one mass shooting after another has led some churches to start training and arming their worshippers with guns. Not all security experts support this approach, but it has gained momentum as congregations across the country grapple with how to secure spaces where welcoming strangers is a religious practice.