Floyd Lee Corkins, seen here in a France TV video image last summer, was sentenced Thursday to 25 years in prison after pleading guilty in February in the Family Research Council shooting. (Courtesy of France TV)

The man convicted of shooting an unarmed security guard at the Family Research Council last summer was sentenced Thursday to 25 years in prison.

Floyd Lee Corkins II had plotted to kill “as many people as possible” at conservative organizations that he viewed as anti-gay before he was stopped by the guard, Leonardo Johnson.

U.S. District Chief Judge Richard W. Roberts called Corkins’s crime “horrific” and praised Johnson, who was shot in the forearm while subduing Corkins and taking his gun.

“The carnage you wanted did not happen only because an ordinary man showing extraordinary courage stopped you,” Roberts told Corkins before announcing his prison term. “Killing human beings is not political activism. It is criminal behavior.”

Corkins’s crime took on new resonance after a gunman opened fire this week at the Washington Navy Yard, claiming the lives of 12 people.

Leo Johnson poses for a portrait in Washington. Johnson was shot in the arm while at work at the Family Research Council when an intruder opened fire at the conservative-leaning think tank in downtown D.C. (Nikki Kahn/The Washington Post)

In arguing for a stiffer sentence of 45 years, federal prosecutors equated Corkins with Aaron Alexis, the man behind Monday’s shooting rampage.

“Mr. Corkins was this close to accomplishing that,” Assistant U.S. Attorney T. Patrick Martin said. “He was no less determined than the Navy Yard gunman. He was no less prepared.”

Corkins, who suffers from chronic mental illness, bought a semiautomatic pistol from a Virginia gun shop six days before the August 2012 shooting. Defense attorney David Bos recommended a sentence of 111 / 2 years and said the case was about “too easy access to firearms.”

Virginia law prohibits firearm sales to people deemed by a judge to be mentally “incapacitated,” but Corkins had no criminal record.

“There is no question that this is a terrifying case for the victims,” Bos said, adding that Corkins is “deeply remorseful.”

In the most dramatic moment of the hearing, Johnson addressed Corkins directly from the courtroom lectern as more than a dozen of his colleagues from the Family Research Council watched.

Johnson, who has returned to work as the building operations manager, told his assailant: “Although I forgive you, I will never forget. I don’t know if I’ll ever be the same again.”

Floyd Lee Corkins is seen entering the lobby of Family Research Council building on Aug. 15, 2012, in this security camera video while armed with a loaded semi-automatic pistol. Leo Johnson was at the front desk and was shot in the forearm, but was able to wrestle the gun away from Corkins. (Courtesy of Family Research Council )

Corkins told the judge that he was struggling with a lifelong illness and briefly apologized to Johnson and to employees of the conservative think tank.

“Obviously, I disagree with them, but I realize it’s not okay to resort to violence,” said the 29-year-old from Herndon.

In February, Corkins pleaded guilty to three felony charges: a federal charge of transporting a firearm and ammunition across state lines, and D.C. charges of assault with intent to kill and committing an act of terrorism while armed.

Corkins, who volunteered at a gay community center in the District, told investigators that he was angry with organizations he considered anti-gay, such as the Family Research Council and the fast-food chain Chick-fil-A. The head of the restaurant chain had spoken out at the time against same-sex marriage.

In a multimedia presentation in the courtroom, federal prosecutors described Corkins’s planning of the shooting as “deliberate and clear-headed.”

The day before, Corkins had purchased 15 Chick-fil-A sandwiches that he carried in his backpack along with the 9mm SIG Sauer pistol. He planned to “smear” the sandwiches in the faces of his victims to make a political statement, according to court documents.

Just before 11 a.m. Aug. 15, Corkins gained access to the building by telling Johnson that he was interested in an internship. When Johnson asked to see Corkins’s identification, he reached into his backpack and pulled out his gun.

Corkins fired three times, striking Johnson in the left forearm.

At the scene, police found a handwritten list in Corkins’s front pants pocket with the names of three other socially conservative organizations. Had he succeeded with the shooting, Corkins told FBI agents, he planned to go directly to the second organization.

Corkins’s attorney said a lesser sentence was appropriate because his client had been suffering from severe mental problems.

Six months before the shooting, Corkins was voluntarily committed to a mental hospital in San Francisco because he was having hallucinations and “thoughts of killing his parents and conservative right-wing Christians,” according to court filings.

Corkins was diagnosed with a major depressive disorder with psychotic features and was taking medication to treat his illness.

In March 2012, Corkins returned home to Northern Virginia at his parents’ request. He continued with treatment at a Falls Church clinic and met with a therapist weekly.

In June 2012, his psychiatrist changed his medication to a monthly shot of an antipsychotic drug. The next month, Corkins received a second shot, and his psychiatrist noted that Corkins “was no longer experiencing any depression or desire to harm himself or others.”

Corkins missed his next shot, scheduled for Aug. 14, the day before the shooting.

“When questioned by the police after his arrest,” Bos said, “it was apparent the demons that led Mr. Corkins to seek treatment in San Francisco six months earlier had returned.”