AMMAN, Jordan — A crime scene investigator told a military court Tuesday that three U.S. military trainers killed at the gate of a Jordanian air base had come under heavy fire, including from inside a nearby guard house.

The investigator testified in the murder trial of a Jordanian soldier who has been accused of killing three U.S. Army Green Berets at the entrance to the base in November.

The defendant, 1st Sgt. Marik al-Tuwayha, stood silently in a cage in the courtroom Tuesday, as he had done during two previous days of testimony this week. The fathers of two of the slain Americans sat just meters away from him, following the proceedings through a translator.

Al-Tuwayha has pleaded “not guilty” and the judge has said the defendant has no apparent ties to terrorist groups.

Jordan is a U.S. ally in the region, including in the campaign against Islamic State extremists who control areas of neighboring Syria and Iraq.

The deadly Nov. 4 shooting at the al-Jafr air base appeared to strain those ties at one point. Jordanian officials initially claimed the U.S. soldiers triggered the shooting by disobeying orders of Jordanian troops guarding the gate of the air base. Jordan later withdrew this claim and King Abdullah II cleared the soldiers of any wrongdoing in a letter to the parents.

The victims were 27-year-old Staff Sgt. Matthew C. Lewellen of Kirksville, Missouri; 30-year-old Staff Sgt. Kevin J. McEnroe of Tucson, Arizona; and 27-year-old Staff Sgt. James F. Moriarty of Kerrville, Texas.

Witnesses have said that a four-car convoy approached the entrance of the base sometime before noon on Nov. 4.

The first vehicle passed through an outer and an inner gate, entering the base safely. Three more vehicles carrying U.S. troops stood between the outer and inner gate when Jordanian gate guards said they heard a low sound, possibly a pistol shot, from the direction of the convoy.

At the time, the defendant was in the guard house, close to the inner barrier, to recharge the battery of his wireless device, witnesses have said.

The crime scene investigator said Tuesday that multiple rounds were fired from two M-16 assault rifles, including from inside the guard house where cartridges were later found.

The vehicle closest to the inner barrier, with McEnroe behind the wheel and Lewellen in the passenger seat, was just a few feet from the guard house.

Moriarty’s father, James, who repeatedly watched a security camera video of the shooting at an FBI office in the U.S., said the defendant fired from inside the guard house at that vehicle, killing McEnroe and Lewellen.

Moriarty has said the video also showed his son and a surviving U.S. soldier jumping out of the two vehicles behind the lead car, taking cover behind large cement blocks and returning fire while shouting at the shooter to halt fire. Witnesses have said the firefight lasted several minutes.

A total of 78 bullets were fired from the M-16 rifles, said Moriarty and a defense lawyer, citing the investigator’s testimony. They said 19 bullets were fired from pistols used by the U.S. troops.

The investigator said each of the three vehicles carrying Americans was hit by gunfire.

Moriarty, a 70-year-old trial lawyer from Houston, said the large number of shots fired from the M-16s suggests that the assailant “had to reload again and again and again.”

Three Jordanian gate guards testified Monday that they held their fire after hearing the apparent pistol shot that ostensibly triggered the violent events because they couldn’t identify the exact source of the sound.

McEnroe’s father, Brian, also attended this week’s sessions at the military court on the outskirts of the Jordanian capital of Amman.

The two fathers were to return to the U.S. on Thursday.