Ricky Pearsall's NFL dreams came true in April when the San Francisco 49ers called to tell him they had selected him with the 31st pick of the 2024 draft.

But a nightmare situation Aug. 31 nearly cost the wide receiver much more than his football career. 

As the 23-year-old walked alone to his car that day, a 17-year-old suspect allegedly noticed the NFL player was wearing a luxury watch and attempted to steal it. 

During a struggle, Pearsall and the teenager were wounded by shots from the teen's gun. Niners head coach Kyle Shanahan shared some details about his message to the team shortly after learning of the shooting.

CLICK HERE FOR MORE SPORTS COVERAGE ON FOXNEWS.COM

Ricky Pearsall rubs head

Ricky Pearsall of the San Francisco 49ers during training camp at SAP Performance Facility July 31, 2024, in Santa Clara, Calif. (Michael Zagaris/San Francisco 49ers/Getty Images)

Shanahan said he spoke to Pearsall by phone not long after he was injured, and 49ers general manager John Lynch went to the hospital to check on the rookie.

TEEN ARRESTED IN SHOOTING OF 49ERS ROOKIE RICKY PEARSALL 'VERY SORRY,' ATTORNEY SAYS

Shanahan, who is entering his eighth season as the Niners' head coach, also noticed the mood of the team shifted after Pearsall's teammates learned about what happened.

"Yeah, once everyone walked in. No one knew the exact story, so I was able to reassure everybody as soon as they got there that he was totally fine, and it's a miracle," Shanahan told the media Thursday. "I think where he got shot is like two inches below his tattoo with praying hands. The whole story is kind of amazing."

Kyle Shanahan looks on field

Head coach Kyle Shanahan of the San Francisco 49ers before the NFC championship game against the Detroit Lions at Levi's Stadium Jan. 28, 2024, in Santa Clara, Calif. (Michael Zagaris/San Francisco 49ers/Getty Images)

Shanahan added that Pearsall was eventually able to join a FaceTime call with his teammates.

"But to tell everyone as soon as they get in — you can't call a whole team — but to tell everyone right when they got there, it was really cool. And then, about two hours later, Ricky got on and talked to everybody."

Ricky Pearsall on field

San Francisco 49ers wide receiver Ricky Pearsall smiles during 49ers rookie minicamp at Levi’s Stadium in Santa Clara, Calif. (Robert Kupbens/USA Today Sports)

Pearsall's mother, Erin Pearsall, posted on social media that the bullet went through the right side of her son’s chest and exited his back without striking any vital organs.

Pearsall was released Sunday from San Francisco General Hospital and Trauma Center. He was at the team's training site Monday, Lynch said Tuesday. The 49ers placed Pearsall on the non-football injury list, giving him time to recover from the shooting and a shoulder injury that had limited him all summer, Lynch confirmed.

CLICK HERE TO GET THE FOX NEWS APP

A high school senior charged with attempted murder in the daytime weekend shooting of Pearsall was arraigned in juvenile court Wednesday and said through his attorney he was sorry for what happened.

The Associated Press contributed to this report.

Follow Fox News Digital’s sports coverage on X, and subscribe to the Fox News Sports Huddle newsletter.