The Saudi airman who killed three and wounded eight at Naval Air Station Pensacola began the 15-week process of buying the murder weapon back in April, officials told The Daily Beast.

“He’d been thinking about this for a long time it looks like,” one senior law enforcement official said.

The FBI said at a press conference Sunday that it is treating Friday’s attack by Mohammed Alshamrani, a second lieutenant in the Royal Saudi Air Force, as an act of terrorism but have not determined if he was motivated by an “ideology” or if he had help.

They have pieced together a timeline of his movements before he killed three American military members and wounded eight others—from the gun purchase, to a visit to the 9/11 Memorial and Museum in New York City last month, to a dinner party where he showed other Saudis video of mass shootings, the officials said.

As of Sunday afternoon, the senior law enforcement official and investigators had no indication that the other Saudi trainees were involved in the shooting. They are said to have told investigators they noticed nothing unusual about Alshamrani during the New York trip from Nov. 28 to Dec 1.

Alshamrani had been back in Florida for three days when he hosted the Dec. 4 dinner party for his fellow Saudis, and showed them the macabre videos.

Several Saudis were seen taking cellphone videos near the shooting scene, but the sources said they seem to have been gawkers who had begun filming just as anyone might on seeing the arrival of numerous emergency vehicles.

“Nothing before the fact, nothing during,” the official said of the footage found in the trainees’ phones.

Three young U.S. service members were killed in Alshamrani’s ambush before deputies fatally shot the gunman. Officials have said he used a legally purchased handgun, but sources have provided new details about how he got the gun.

In mid-April, Alshamrani obtained a Florida hunting license he would use to take advantage of a loophole in federal law, that allows foreign nationals with a valid visa to acquire firearms if “in possession of a hunting license or permit lawfully issued in the United States.”

He selected a 9mm Glock 45 semiautomatic pistol with an extended magazine at a gun shop in the Pensacola area.

“What are you going to hunt with a Glock 45 with an extended magazine?” one investigator wondered. “People.”

The gun shop is said to have checked with authorities to confirm the validity of the visa Alshamrani received when he arrived in America in August of 2017 from Riyadh for military training.

By the end of this July, Alshamrani had completed purchase of the weapon, which he could not legally carry onto the Naval Air Station in Pensacola where he was to begin flight instruction. He also would not have been able to carry the Glock aboard a plane when he returned to his country after completing his U.S. training..

“I’m not sure he’s got the status to bring a gun back to Saudi,” a senior law enforcement official told the Daily Beast.

He presumably did not have the gun with him when he flew to New York on Nov. 28, just before Thanksgiving, with either two or three fellow Saudi trainees. There, he met up with three other Saudis who have been undergoing military training elsewhere in the U.S.

The law enforcement sources said the Saudis stayed at a lower-end hotel in midtown Manhattan and visited the Statue of Liberty, Central Park, the famous Christmas tree at Rockefeller Center, and the 9/11 museum.

“All the places they went were all the places the tourists go see what this country's all about,” an investigator observed.

The investigator further noted that the museum has on display pictures of the 19 hijackers attacked the U.S. on Sept. 11, 2001. Fifteen of them were Saudi citizens.

One of the remaining questions about Alshamrani is whether he acted on his own or was some kind of sleeper agent recruited and groomed to get into a position where he could kill American military personnel on American soil.

If the answer is the latter, it raises another question: Why wouldn’t the groomers wait until Alshamrani could wield a weapon capable of causing even more damage than his Glock?

“Get him up in an F-15 and crash it into a building or drop a bomb,” the senior official said.

On his trip to New York, Alshamrani had to pass through metal detectors not just at the airports, but also at the 9/11 museum and the Statue of Liberty. He underwent no such screening at NAS Pensacola early Friday morning.

With the extended magazine in the Glock and other magazines on his person, and Alshamrani might have killed many more than three had the people he shot and the deputies who then shot him not shown such courage—exactly the kind of bravery demonstrated 18 years ago by so many of those honored by the 9/11 Memorial and Museum.