Mona Rodriguez holds her 12-year-old son, J Anthony Hernandez, during a candlelight vigil held for the victims of a fatal shooting at the First Baptist Church of Sutherland Springs, Sunday, Nov. 5, 2017, in Sutherland Springs, Texas. (Nick Wagner/Austin American-Statesman via AP)

A gunman dressed in black tactical-style gear and armed with an assault rifle opened fire inside a small South Texas church, killing 26 people in an attack that claimed tight-knit neighbors and multiple family members ranging in age from 5 to 72 years old.

Once the shooting started Sunday at the First Baptist Church in Sutherland Springs, there was likely "no way" for congregants to escape, said Wilson County Sheriff Joe D. Tackitt Jr. Officials said about 20 others were wounded.

"He just walked down the center aisle, turned around and my understanding was shooting on his way back out," said Tackitt, who said the gunman also carried a handgun but that he didn't know if it was fired. Tackitt described the scene as "terrible."

"It's unbelievable to see children, men and women, laying there. Defenseless people," he said.

Authorities didn't identify the attacker during a news conference Sunday night. But two other officials — one a U.S. official and one in law enforcement — identified him as Devin Kelley. They spoke to The Associated Press on the condition of anonymity because they weren't authorized to discuss the investigation.

The U.S. official said Kelley lived in New Braunfels, northeast of San Antonio, and didn't appear to be linked to organized terrorist groups. Investigators were looking at social media posts Kelley made in the days before the attack, including one that appeared to show an AR-15 semiautomatic weapon.

Kelley received a bad conduct discharge from the Air Force for assaulting his spouse and child, and was sentenced to 12 months' confinement after a 2012 court-martial. Kelley served in Logistics Readiness at Holloman Air Force Base in New Mexico from 2010 until his 2014 discharge, Air Force spokeswoman Ann Stefanek said.

At the news conference, the attacker was described only as a white man in his 20s who was wearing black tactical gear and a ballistic vest when he pulled into a gas station across from the church, about 30 miles (48.28 kilometers) southeast of San Antonio, around 11:20 a.m.

The gunman crossed the street and started firing the rifle at the church, said Freeman Martin, a regional director of the Texas Department of Safety, then continued firing after entering the white wood-frame building, where an 11 a.m. service was scheduled.

As he left, the shooter was confronted by an armed resident who "grabbed his rifle and engaged that suspect," Martin said. A short time later, the suspect was found dead in his vehicle at the county line.

Federal agents, including ATF investigators and the FBI's evidence collection team, swarmed the small rural community of just hundreds of residents.

Several weapons were found inside the vehicle and Martin said it was unclear if the attacker died of a self-inflicted wound or if he was shot by the resident who confronted him. He said investigators weren't ready to discuss a possible motive.

Martin said 23 of the dead were found in the church, two were found outside and one died after being taken to a hospital.

The man who confronted Kelley had help from another local resident, Johnnie Langendorff, who told media outlets that he was driving past the church as the shooting happened. He didn't identify the armed resident but said the man exchanged gunfire with the gunman, then asked to get in Langendorff's truck and the pair followed as the gunman drove away.

Langendorff said the gunman eventually lost control of his vehicle and crashed. He said the other man walked up to the vehicle with his gun drawn and the suspect did not move. He stayed there for at least five minutes, until police arrived.

"I was strictly just acting on what's the right thing to do," Langendorff said.

Among those killed was the church pastor's 14-year-old daughter, Annabelle Pomeroy. Pastor Frank Pomeroy and his wife, Sherri, were both out of town when the attack occurred, Sherri Pomeroy wrote in a text message.

"We lost our 14-year-old daughter today and many friends," she wrote. "Neither of us has made it back into town yet to personally see the devastation. I am at the charlotte airport trying to get home as soon as i can."

Church member Nick Uhlig, 34, who wasn't at Sunday's service, told the AP that his cousin, who was 8 months pregnant, and her in-laws were among those killed. He later told the Houston Chronicle that three of his cousin's children also were slain.

Sunday evening, two sheriff's vans were parked outside the gate of a cattle fence surrounding the address listed for Kelley on the rural, western outskirts of New Braunfels, north of San Antonio.

Ryan Albers, 16, who lives across the road, said he heard intensifying gunfire coming from that direction in recent days.

"It was definitely not just a shotgun or someone hunting," Albers said. "It was someone using automatic weapon fire."

The church has posted videos of its Sunday services on a YouTube channel, raising the possibility that the shooting was captured on video.

In a video of its Oct. 8 service, a congregant who spoke and read Scripture pointed to the Oct. 1 Las Vegas shooting a week earlier as evidence of the "wicked nature" of man. That shooting left 58 dead and more than 500 injured.

Gov. Greg Abbott called Sunday's attack the worst mass shooting in Texas history. It came on the eighth anniversary of a shooting at the Texas' Fort Hood, where 13 people were killed and 31 others wounded by a former U.S. Army major.

The previous deadliest mass shooting in Texas had been a 1991 attack in Killeen, when a mentally disturbed man crashed his pickup truck through a restaurant window at lunchtime and started shooting people, killing 23 and injuring more than 20 others.

The University of Texas was the site of one of the most infamous mass shootings in modern American history, when U.S. Marine sniper Charles Whitman climbed the Austin campus' clock tower in 1966 and began firing on stunned people below, killing 13 and wounding nearly three dozen others. He had killed his wife and mother before heading to the tower, one victim died a week later and medical examiners eventually attributed a 17th death to Whitman in 2001.

___

Associated Press writers Sadie Gurman and Eric Tucker in Washington, Nomaan Merchant in Houston, Will Weissert in Austin, Diana Heidgerd in Dallas, Michael Balsamo in Los Angeles and Paul J. Weber in New Braunfels, Texas, contributed to this report.