NASHVILLE, Tenn. — The suspect in a deadly Waffle House shooting was ordered to receive treatment in a mental facility for schizophrenia in hopes that he becomes fit to stand trial.

Travis Reinking, 29, learned his fate in court Aug. 22 just feet away from the man who authorities say wrestled an assault-style rifle away during the April shooting in Nashville that killed four people. It was the first time James Shaw Jr. saw Reinking since the act of heroism that has since landed him budding celebrity status.

Dozens of those close to the victims also were on hand, many wearing matching memorial shirts for their fallen family members and friends.

Davidson County Criminal Court Judge Mark Fishburn said Reinking poses a substantial threat of harm to the public, if not himself.

Wearing a yellow jail jumpsuit, Reinking remained quiet until the end of the hearing, when he seemed to begin saying something about his "religion" before a court officer and his public defender stopped him from speaking.

Shaw, 29, who has been hailed as the hero who disarmed the gunman during the April 22 shooting, wore a T-shirt and shorts as he watched the proceedings from the audience. He gave a few hugs on his way out and did not speak to reporters, then later tweeted about the experience.

"I was discouraged to hear the current prognosis of the shooter, but I believe Justice will be served, I had to remember patience is a virtue and to walk by faith not by sight everything happens in due time," Shaw said in a tweet that also includes the four victims' names.

Reinking was nearly naked and wearing only a green jacket when he opened fire outside the restaurant with an assault-style rifle and then stormed the Waffle House, police have said.

Forensic psychologist Rena Isen testified that Reinking was currently unfit for trial, saying Reinking wasn't complying with his medication, which could potentially treat his illness.

Victims' relatives and friends groaned and mumbled at the testimony, and some were on the verge of tears.

Updates on Reinking's condition are due every six months, though if he becomes fit to stand trial, Fishburn said to notify him immediately.