Attorneys for Florida school shooter Nikolas Cruz suddenly and surprisingly rested their case Wednesday after calling only a fraction of their expected witnesses, leading to a shouting match after the judge accused them of a lack of professionalism.

Cruz's attorneys had told the judge and prosecutors they would be calling 80 witnesses but rested at the beginning of Wednesday's court session after calling only about 25. There were 11 days of defense testimony overall, the last two spotlighting experts about how his birth mother's heavy use of alcohol during pregnancy might have affected his brain's development and led to his murder of 17 people at Parkland's Marjory Stoneman Douglas High School four years ago.

The sudden announcement by lead attorney Melisa McNeill led to a heated exchange between her and Circuit Judge Elizabeth Scherer, who called the decision without warning to her or the prosecution "the most uncalled for, unprofessional way to try a case."

The 12-member jury and 10 alternates were not present but were lining up outside the courtroom to enter. The sudden announcement also meant prosecutors weren't ready to start their rebuttal case.

Marjory Stoneman Douglas High School shooter Nikolas Cruz is shown at the defense table

Marjory Stoneman Douglas High School shooter Nikolas Cruz is shown at the defense table just before his defense team announced their intention to rest their case during the penalty phase of Cruz's trial at the Broward County Courthouse in Fort Lauderdale on Wednesday, Sept. 14, 2022. Cruz previously plead guilty to all 17 counts of premeditated murder and 17 counts of attempted murder in the 2018 shootings. (Amy Beth Bennett/South Florida Sun Sentinel via AP, Pool)

PARKLAND SHOOTING TRIAL: JUDGE LASHES OUT AT DEFENSE LAWYERS AFTER THEY RESTED THEIR CASE

Lead prosecutor Mike Satz threw his hands up when Scherer asked if he could begin and, with a nervous laugh, said "no."

"We’re waiting for 40 more (defense) witnesses," Satz said.

Scherer then accused Cruz's attorneys of being inconsiderate to all involved, but especially the jurors for wasting their trip to court.

"To have 22 people march into court and be waiting as if it is some kind of game. I have never experienced such a level of unprofessionalism in my career," Scherer said, raising her voice.

McNeill countered angrily, "You are insulting me on the record in front of my client," before Scherer told her to stop. Scherer then laid into McNeill, with whom she has had a testy relationship since pretrial hearings began more than three years ago.

"You’ve been insulting me the entire trial," Scherer barked at McNeill. "Arguing with me, storming out, coming late intentionally if you don’t like my rulings. So, quite frankly, this has been long overdue. So please be seated."

Marjory Stoneman Douglas High School shooter Nikolas Cruz is sworn in during the penalty phase

Marjory Stoneman Douglas High School shooter Nikolas Cruz is sworn in during the penalty phase of Cruz's trial at the Broward County Courthouse in Fort Lauderdale on Wednesday, Sept. 14, 2022. His defense team announced their intention to rest their case. Cruz previously plead guilty to all 17 counts of premeditated murder and 17 counts of attempted murder in the 2018 shootings. (Amy Beth Bennett/South Florida Sun Sentinel via AP, Pool)

Cruz, 23, pleaded guilty last October to murdering 14 Stoneman Douglas students and three staff members on Feb. 14, 2018. His trial, now ending its second month, is only to determine whether he is sentenced to death or life without parole. For a death sentence, the jury must be unanimous.

After his attorneys rested, Cruz told Scherer he agreed with the decision.

"I think we are good," he said.

When jurors were told of the decision, several stared at the defense table, appearing stunned.

Cruz's attorneys have tried to show how his late birth mother's alcohol abuse during pregnancy put Cruz onto a lifelong path of erratic, bizarre and often violent behavior that culminated in the shootings. They also tried to show that his adoptive mother, Lynda Cruz, became overwhelmed after her husband died when Cruz was 5.

They called witnesses who knew his birth mother, Brenda Woodard, a Fort Lauderdale prostitute. They testified she drank fortified wine and malt liquor and abused cocaine during her pregnancy.

They called Cruz's psychiatrists and psychologists and teachers from his preschool, elementary and middle school years — they all testified he was a slow developing child who hurt others, had frequent outbursts, made threats and had few friends.

The defense concluded their case by calling Dr. Kenneth Jones, one of the nation's leading fetal alcohol experts, who said in his five decades of research he had never seen a birth mother who had more documented drinking than Woodard. He believes Cruz's doctors didn't properly diagnose him with fetal alcohol spectrum disorder, meaning he never got the right treatment.

But Cruz's attorneys had been expected to call his younger half-brother, Zachary, who was a central figure in their case with witnesses accusing him of bullying his smaller, weaker brother. They also presented no witnesses from the school for students with behavioral problems that Cruz attended and no witnesses to discuss his troubled days attending Stoneman Douglas, where he was frequently searched for weapons.

Two attorneys who have followed the trial are stunned by the defense's decision.

"Wow. That is a shocker," said David Weinstein, a Miami defense attorney and former prosecutor. He said perhaps the defense was worried the prosecution's cross-examination of their witnesses was hurting their case, but "I am surprised that there was no testimony about his high school years or more about" Cruz.

Robert Jarvis, a professor at Nova Southeastern University's law school near Fort Lauderdale, said the decision is hard to fathom.

"Perhaps the defense felt it had made its case. Perhaps the defense felt it was losing the jury and further witnesses would only alienate the jury. Perhaps the defense felt that the witnesses to be called would give the prosecution too much leeway to explore matters during cross-examination that the defense did not want explored," Jarvis said.

Still, he said Scherer's dressing down of McNeill was uncalled for. He has been an outspoken critic of Scherer's selection to oversee such a complicated case — she had never tried a first-degree murder trial before being assigned Cruz's.

"It was the defense’s right to rest when it thought the right moment was reached. Indeed, I have never heard of a judge effectively demanding that a party call all its proposed witnesses," Jarvis said. "This is just another example of Judge Scherer not being the right judge."

FLORIDA SCHOOL SHOOTING TRIAL: PSYCHOLOGIST SAYS PARKLAND SHOOTER SUFFERED FETAL ALCOHOL DAMAGE

The defense is trying to overcome the prosecution’s case, which focused on Cruz’s massacre as he stalked a three-story classroom building for seven minutes with an AR-15-style semiautomatic rifle. Satz played security videos of the shooting and showed the rifle Cruz used. Teachers and students testified about watching others die.

CLICK HERE TO GET THE FOX NEWS APP

Satz showed graphic autopsy and crime scene photos and took jurors to the fenced-off building, which remains blood-stained and bullet-pocked. Parents and spouses gave tearful and angry statements about their loss.

Prosecutors said they will need more than a week to prepare their rebuttal case. The trial is now tentatively scheduled to resume Sept. 27 and conclude the week of Oct. 10.

AP writer Freida Frisaro in Miami contributed to this report.