The FBI wanted Adel Daoud to understand the destruction he could cause — and the number of lives that would be lost — if he followed through with his plan in 2012 to blow up a downtown Chicago bar.

The feds handed him a 1,000-pound inert car bomb that year as its months-long investigation of Daoud neared its end. However, an undercover agent said he also told Daoud to view videos of car bombs online to “visualize and understand that this will be a devastating explosion.”

If Daoud had gotten cold feet, that agent testified Tuesday, “we were ready until the last moment to walk away.”

Instead, Daoud said a prayer on Sept. 14, 2012. He parked the inert car bomb in front of the Cactus Bar and Grill. Then, Daoud pressed the detonator button and was quickly arrested. Now, more than six years later, Daoud faces sentencing for that attempted bombing and other crimes in a trial-length hearing this week at the Dirksen Federal Courthouse.

The most dramatic day of testimony likely arrived Tuesday, when U.S. District Judge Sharon Johnson Coleman cleared her courtroom to hear from the undercover FBI agent who Daoud, now 25, believed to be his ally back in 2012.

The judge did so over the objection of lawyers for Daoud and the media, making audio of the agent’s testimony available in a separate courtroom. Video of the proceedings could also be seen, though the agent did not appear on-screen.

Following his arrest in 2012, Daoud tried to have the same agent killed. He also tried to kill a fellow jail inmate in 2015, leaving the inmate covered in blood. Daoud admitted to the facts revolving around those charges — but continued to deny culpability — in a specialized guilty plea last fall known as an Alford plea.

The undercover agent used the name “Mudafer” when he met the then 18-year-old Daoud in July 2012. He said Daoud believed him to be 28. After meeting briefly at a mosque, the agent said he spoke with Daoud for about two hours at a park in Villa Park. He said Daoud spoke 90 percent of the time, bringing up the Sept. 11, 2001, terrorist attacks, Osama Bin Laden and Anwar al-Awlaki.

He also self-identified as a terrorist, the agent said.

Prosecutors played audio clips of the meeting Tuesday. In the recordings, Daoud comes across as a babbling, opinionated teenager. Though his comments are sometimes hard to make out, his voice rises and falls wildly. And he laughs often.

The laughter didn’t faze the agent, who said he’s heard the same from other terrorism suspects.

“They were all excited and happy about following through with their terrorist plan,” the agent said.

In a reference to the Sept. 11 attacks, Daoud said, “maybe it’s wrong to kill those people. But, didn’t they have it coming? I mean, you kind of did it first, I mean. It was, I mean, it was like, it was like your fault. You started it.” He added later, “what did you expect?”

The agent repeatedly said he tried to give Daoud opportunities to cool down and give up on his ideas. He said he did not try to pressure Daoud into any specific plan. Still, Daoud produced a handwritten list of potential bombing targets that included Woodfield Mall, an address on Navy Pier, bars and military offices.

Ultimately, the agent said, “(Daoud) picked the target. He picked the use of the car bomb. He picked the date.”

Defense attorney Thomas Anthony Durkin questioned the agent about his methods and whether the FBI truly perceived Daoud as a threat. He asked whether the agent “genuinely believed that Daoud could have walked away from you and gone online and found someone else to build a 1,000-pound bomb for him?”

“(Daoud) specifically told me that he researched online how to build a bomb,” the agent said. He added that, “building a bomb is not as difficult as we think.”

During his first meeting with the undercover agent, Daoud suggested an attack that involved a “flying car.” Daoud’s lawyers have said that comment “reveals a level of idiocy” that undermines the image of Daoud as a threat.

The agent testified Tuesday that he looked into the idea.

“They do exist, so you could purchase one,” the agent said.