In 2012, while stationed at an Air Force base in New Mexico, Kelley was court-martialed and sentenced to a year's confinement for abusing his wife and child. The Air Force's chief prosecutor at the time told the New York Times and NBC News that Kelley broke his stepson's skull.
Two years later, soon after he was given a bad conduct discharge for his crime, Kelley was cited for animal cruelty after neighbours told police he viciously punched his dog outside his trailer home, according to a report from the El Paso County sheriff's office. Court records show the case was dismissed after he paid a fine.
His behavioural problems appear to have started much earlier. A former girlfriend said Kelley engaged in years of harassment, bordering on stalking, after a brief relationship nearly a decade ago, and classmates from his Texas hometown described a "loner" who became increasingly disturbed as a teenager.
Domestic problems may have triggered Sunday's shooting, as well. Authorities said on Monday that he had sent threatening text messages to his mother-in-law, who sometimes attended First Baptist Church in Sutherland Springs but was not there on Sunday when Kelley opened fire.
"There was a domestic situation going on within the family and the in-laws," Freeman Martin, a spokesman for the Texas Department of Public Safety, told reporters. Kelly was found dead from an apparent self-inflicted gunshot wound after fleeing the church.
The former girlfriend, Brittany Adcock, said she dated Kelley nearly a decade ago, when he was 18 and she was only 13.
The relationship lasted for about four months, but Kelley would harass her with phone calls from blocked numbers and Facebook messages from fake accounts for years afterward, she said in an interview.
Adcock said she once called police to try to file a complaint and had to change her number to stop Kelley's calls.
"He just started getting really weird," Adcock, now 22, said.
He last contacted Adcock about six months ago via Facebook, when he sent her a topless photo of someone else he had found online and appeared to think it was her, she said.
That year, he married Danielle Shields in Texas, and they lived in Colorado Springs for a time before returning to New Braunfels, according to public records. Attempts to reach Shields or her parents were unsuccessful.
Mental Health Problems
Former schoolmates of Kelley said he may have had some mental health problems even as a teenager.
Reid Mosis, 26, who attended school in New Braunfels with Kelley from 6th through 9th grades, said in an interview that Kelley was "always a bit of a loner."
"I know his parents had him on heavy doses of meds in middle school," Mosis said. "A lot of friends that knew him said he was too sick in the head to deal with by senior year of high school."
In recent years, Kelley shared posts on Facebook about atheism and his assault weapon, Mosis said. A cached photo of Kelley's Facebook page, which was deleted in the wake of the shooting, showed a photo of a rifle under which Kelley wrote, "She's a bad bitch."
Another New Braunfels native, Courtney Kleiber, said on Facebook she was close with Kelley in middle and high schools and that he had slowly changed from a "normal" kid into one with emotional or mental problems.
"Over the years we all saw him change into something that he wasn't," she wrote. "To be completely honest, I'm really not surprised this happened, and I don't think anyone who knew him is very surprised either."
(This story has not been edited by NDTV staff and is auto-generated from a syndicated feed.)
Follow NDTV for latest election news and live coverage of assembly elections 2019 in Maharashtra and Haryana.
Subscribe to our YouTube channel, like us on Facebook or follow us on Twitter and Instagram for latest news and live news updates.