Omari Spellman knew what he wanted to do when he stopped by Villanova head coach Jay Wright’s office in April 2018. Fresh off shooting 43.3% from 3-point range for the national champion Wildcats, Spellman was hearing he’d go in the first round in the NBA draft.

Wright told Spellman that he was ready from a basketball standpoint, but he was worried Spellman would have a tough time living on his own. In his two years at Villanova, Spellman had shown that, to maximize his potential, he required a structured environment and around-the-clock support from his coaches.

But as Wright spoke, Spellman struggled to listen. His mind already was filled with thoughts of sports cars and a house for his mother. Over the next year, as weight issues derailed his stint with the Atlanta Hawks, Spellman would reflect often on that conversation with Wright.

Fueled by the desire to make the Hawks regret trading him, Spellman, 22, has shed 55 pounds from his 6-foot-8 frame since July. Able to give all-out effort for longer stretches, he has emerged as the Warriors’ primary backup at center.

Before suffering a sprained left ankle that is expected to sideline him for a second game Wednesday against the Lakers, Spellman displayed a mix of physicality, shooting and defensive versatility. Those closest to him have seen a changed man. After slogging through a year-long depression, Spellman is finally finding reasons to smile again.

“I have a great opportunity with the Golden State Warriors,” said Spellman, who had his third-year option of $2 million exercised two weeks ago. “They’re helping me every day. I’m losing more and more weight, and I can really get to whatever point they want me at. I know what I need to do.”

This is key because, for much of his rookie season with the Hawks, Spellman felt lost. Living on his own in Atlanta, he couldn’t stave off an overwhelming sense of isolation. After leaving the practice facility early in the afternoon on off-days, Spellman would sequester himself in his room, leaving only to pick up his DoorDash order or make late-night trips to Waffle House.

In just six months, he ballooned from 254 pounds to 293, quite the feat for an NBA player midseason. Hawks employees recognized that something was off. An easygoing goofball by nature, Spellman had grown sullen. Texts from teammates went unreturned.

Atlanta’s training staff wanted him to take accountability and ask for help, but the NBA lifestyle had altered with his priorities. Instead of focusing on his diet and cracking the rotation, Spellman did favors for friends and hobnobbed with celebrities.

Wednesday’s game Who: Warriors (2-9) at L.A. Lakers (8-2) When: 7 p.m. TV: NBCSBA, ESPN Radio: 95.7

Read More

Today, he calls that dark period a “time of self-sabotage.” And injuries only worsened his depression. A hip issue, possibly the result of his rapid weight gain, sidelined Spellman for seven games last winter. In early March, a high ankle sprain ended his season.

Just nine months removed from going No. 30 overall in the NBA draft, Spellman was seeing stories repeatedly not include him with Trae Young, John Collins and Kevin Huerter among the Hawks’ promising young core. A barrage of criticism in Spellman’s Twitter mentions also took its toll.

Ever since he was a kid, eating had been his way to cope with stress. Spellman arrived at Villanova in fall 2016 weighing 290 pounds. After failing to qualify as a true freshman, he worked diligently with the school’s training staff, playing the next season at around 250 pounds.

No longer in such a hands-on environment, Spellman had a difficult time taking control of his weight issues last season. In mid-July, after he arrived at Las Vegas summer league weighing 315 pounds, he broke down in tears when he learned that the Hawks were trading him to the Warriors for center Damian Jones and a 2026 second-round pick.

“I had to fall on my face a bunch of times and, unfortunately, Atlanta felt like I had fallen on my face one too many times,” Spellman said. “But that’s part of the business and, more importantly, that’s also a part of growing up. More than anything, it just showed me I need to make some changes.”

Within a couple of weeks of getting traded, Spellman moved into a high-rise apartment complex near Chase Center and began a rigorous workout regimen. Salmon replaced fried chicken in his diet.

As his weight began to drop, his mood lightened. Spellman started meeting regularly with a therapist, who, after hearing about his addiction to social media, convinced him to delete his Twitter and Instagram accounts.

In mid-October, while in Los Angeles for two preseason games against the Lakers, Spellman met Wright — in town for an exhibition against USC — at Villanova’s hotel. For more than an hour, Spellman opened up about his trying rookie season and insisted that he was ready for a fresh start with the Warriors.

Wright was just happy to see him joking with old friends. For much of the previous year, few in Villanova’s program had heard from Spellman. Some had grown increasingly concerned about his well-being.

“I could really see his maturity, what he learned from his experience in Atlanta,” Wright said. “I could see that this was going to be a great opportunity for him because he had grown a lot.”

Spellman realizes that, though he feels good now, he can’t predict when another bout of depression might arrive. His current ankle injury will test his resolve as he toils through rehab away from the team.

But Spellman has discovered new, healthier coping strategies. When he is feeling low, he looks at a picture from a recent weigh-in. The scale reads 259.2 pounds — his ideal playing weight.

“Seeing Jay in L.A., it made me understand that they really care for me,” Spellman said. “For a long time, I ran from them. I was kind of, like, ashamed. Jay was right when he said I wasn’t ready emotionally for the league, but I don’t regret entering the draft.

“I needed to go through what I went through to be where I am today.”

Connor Letourneau is a San Francisco Chronicle staff writer. Email: cletourneau@sfchronicle.com Twitter: @Con_Chron