JaVale McGee resists the easy trope, the redemptive story line of a silly kid who grew up into a savvy veteran. The goofball who ate cinnamon on Twitter and ran back on defense while his exasperated point guard held the ball? That guy hasn’t gone anywhere, McGee insists. He plays — actually plays — for the Golden State Warriors now.

“I’ve been the same goofy guy I’ve been this whole time,” McGee said. “It’s just, I’m around people that didn’t try to change me. They knew who I am and realized, underlying me laughing all the time, I’m actually working hard.”

McGee was thrust into the spotlight last week after an ugly and widely publicized Twitter exchange with Shaquille O’Neal that started when O’Neal broadcast an intricate compilation of McGee’s career gaffes for his “Shaqtin’ a Fool” blooper reel, on which he has made McGee a regular foil.

Taken for granted amid the uproar — which included the mothers of both men weighing in, through comments to The Undefeated — was a simple fact: McGee, the joker who years ago failed out of a bleak Washington Wizards team, has become a functional member of perhaps the greatest basketball team of all time. The Warriors turned McGee into a useful cog on an all-time team not by changing him but by accepting him.

McGee plays a small but valuable role for Golden State, plunged into uncertainty after Kevin Durant hobbled off the floor with a hyperextended left knee less than two minutes into their loss Tuesday night to the Wizards. McGee is averaging 6.1 points and 3.1 rebounds, with almost one blocked shot per game. Coach Steve Kerr praised the way McGee has fit into their “center by committee” rotation, providing a highflying complement to earthbound starter Zaza Pachulia. McGee provides a “lob component” and “vertical spacing” to Golden State’s offense, Kerr said, which makes their shooters harder to defend.

Kerr, in essence, has asked McGee to do only what he excels at: dunk and block shots. And he has welcomed McGee’s eccentricities, assured the team’s culture will absorb, and even benefit from, them.

“He’s been a phenomenal teammate,” Kerr said. “I didn’t know him before. He’s had the reputation of being flighty. I think we all know from the last couple weeks, with the feud with Shaq, there’s always been joking around about JaVale. I’ve found that it’s unfortunate.

“He’s one of the smartest guys I’ve been around. He’s a techie. He’s got his drones. He’s always up to date on every new technological advancement. He’s got funny stories. The team loves him. The coaching staff loves him. Sometimes this league is about opportunity and who you’re playing with. This is a great spot for him, and we hope he’s here for a long time.”

O’Neal was the most prominent figure to pick on McGee but far from the only one, which McGee knew intimately. He has learned to live with his reputation, which he earned as a young player and has since tried to overcome over a nine-year career.

“I have a reputation, unfortunately, of guys that have, like, drug cases,” McGee said. “I feel like I have that stigma, and I haven’t done anything. Literally. Nothing. It’s just crazy the way people portray me.”

McGee has tried to let it slide. It has not been easy, or without hurt.

“They see a blooper here and there, and they just think, ‘Oh, he’s dumb,’ ” McGee said. “I mean, what can I do? I can’t ‘at’ everyone on Twitter and tell them I’m not dumb. Because that looks dumb.

“I’ve let a lot of stuff go over my career. I’m not really a confrontational person. I’m really a last-straw kind of person.”

McGee, 29, appeared on the verge of falling out of the league after last season, when he appeared in just 34 games for the Dallas Mavericks and averaged 5.1 points. But the Warriors provided him an ideal platform on which to revitalize his career.

“All he’s basically doing is blocking shots like he’s done in the past or catching lobs,” said Wizards point guard John Wall, who played/put up with McGee for the first year and a half of his career. “That’s an easy thing for him to do. And I’d say one thing: He’s playing with a lot more energy and a sense of urgency since he’s been with that group of guys.”

At some point in his three and a half seasons in Washington, before the Wizards dealt him to the Denver Nuggets for Nene, McGee’s proclivity for silliness surpassed his soaring dunks in the public view. He filmed himself attempting to eat a spoonful of cinnamon on Twitter, spewing red dust when he could not. He infamously sprinted back on defense while Wall still had the ball. His mother, Pam, an excellent college basketball player, procured tickets close to the Wizards bench and would both holler at coaches and sometimes implore McGee to ignore them.

“He just grew,” Wall said. “He grew up as a person, grew as a player. He’s definitely with a great organization, a lot of talent around him, so he doesn’t have to do too much.”

The Wizards did not place McGee in a position suited to transcend a goofy streak. As a 21-year-old rookie, he could count Andray Blatche, Nick Young and Gilbert Arenas as teammates. “I knew JaVale’s always been one of those guys; he’ll adapt to the environment he’s in,” Durant said.

McGee’s resurfacing provides further proof that NBA success can depend on a player’s situation as much as his ability. Wall presented another Wizard-turned Warrior as an example. Shaun Livingston played alongside Wall for 17 games in 2012, averaging 3.7 points before Washington waived him. Livingston, always respected for his intellect, could blame meager career prospects on injury rather than inanity. But once he left Washington, bounced to two other teams and landed with the Warriors, he emerged as a heady, valuable bench player on a championship team.

“A lot of players in certain situations, you wonder why they don’t look too good or why they’re in the NBA or why they can’t figure it out,” Wall said. “Then they go to a different team.”

With the Warriors, McGee has provided a dependable and enjoyable presence. He has not missed a practice all season. Kerr wields him in short bursts, a concession to his effort. “He plays with this frenetic athleticism that I don’t think anybody could go more than six minutes with,” Kerr said.

“I’m proud of him,” Durant said. “He’s been a great teammate. When he gets his chances, he goes out there and plays extremely hard.”

From McGee’s perspective, nothing has changed besides finding the right team, a coach and a place that will embrace him.

“He’s been fantastic for us,” Kerr said. “He’s having a great year. He’s helped us win a lot of games. And it’s more than that. The joy that he brings to the locker room, the humor, he’s a great teammate.”