MINNEAPOLIS -- The Miami Heat looked for a bit of magic from their retiring star when Dwayne Wade went up for a shot at the buzzer.
All the Minnesota Timberwolves could do was brace for a storybook finish.
Instead, Wade's shot missed the mark, Miami's playoff hopes took a hit and Minnesota enjoyed the role of spoiler in a 111-109 victory Friday night.
Karl-Anthony Towns had 13 points and 12 rebounds for the Timberwolves. Dario Saric scored 19 points, Andrew Wiggins added 18 and Gorgui Dieng finished with a season-high 19 off the bench for Minnesota.
"He's an all-time legend at that, but we got very fortunate," Towns said of Wade's shot. "Usually when you're on your last dance, the basketball gods give you the 3 to go. But we toughed it out the whole game. We played really well and found a way to win."
Wade scored 24 points for the Heat, who missed a chance to pull into a tie with Brooklyn and Detroit in the race for the eighth spot in the Eastern Conference standings.
Wade had a steal and layup to help Miami close within one with 10 seconds left. Timberwolves rookie Keita Bates-Diop hit one of two free throws and Wade's final shot bounced off the rim.
"I was trying to will it in with my body, but it didn't go in," Wade said.
Dion Waiters scored 22 and shot 6 of 12 from 3-point range for the Heat.
Miami, which has lost four of six, had 17 turnovers as Minnesota rode a big second half to the win.
The Heat led 93-92 early in the fourth, but Minnesota slowly pulled out to a six-point edge and held on to win for the third time in five games.
"You want to win in the playoffs, you have to learn how to win pressure games and games with expectations and consequences during the regular season," Heat coach Erik Spoelstra said. "This can't feel any more like the playoffs right now. I just think this is an awesome experience for our team. You have to embrace this and find a way to rise to the challenge."
Wade's final game at Target Center was vintage in the first half. He came off the bench to score 21 points in the first two periods on 7-of-9 shooting. Miami shot 62.2% in the first half and led by as many as nine points.
After giving up 69 points in the first half, the Wolves limited the Heat to 18 points in the fourth quarter. It was Minnesota's best defensive quarter since holding Memphis to 16 points in the first quarter on Jan. 30.
"It's about winning," Towns said. "We're working for the playoffs next year. Even though we can't make it this year, why not start the work right now. We're doing a great job of getting that ball movement going, just finding ways to win."
Heat: Justice Winslow made the start for the injured Josh Richardson (left hip strain). It marked the 27th different starting lineup for Miami this season, the third-most in team history. Winslow has started 48 games this season, but came off the bench in the previous game with Goran Dragic starting. ... Derrick Jones Jr. was questionable with a right knee bone bruise and didn't play. ... Wade was presented with a wrapped gift before the game from Wolves owner Glen Taylor. Wade averaged 24.4 points in 23 career games against Minnesota. He swapped jerseys with Towns after the game.
Timberwolves: Minnesota became the second team in history to allow 1,000 3-pointers in a season, joining the Milwaukee Bucks, who have also done so this season. ... The Wolves are 6-32 when trailing after three periods. ... Kentucky head coach John Calipari was in attendance and sat behind Minnesota's bench. Calipari coached Towns and Miami's Bam Adebayo in college at Kentucky and Wolves guard Derrick Rose at Memphis. Rose was inactive, but stopped by to chat with Calipari during the game.
EMBRACING THE ROLE
After snapping their playoff drought last season, Minnesota is again on the outside of the postseason this year. Yet, Minnesota is enjoying the role of spoiler.
"That's our mindset," Wiggins said. "We're not going to make it, so we've got to make it rough on everybody else."
WADE LEADS THE WAY
Wade has come off the bench in every game this season and is pacing a potent Miami bench. The Heat got 51 points from their reserves on Friday and they have the third-most points, assists, rebounds and steals per game this season.
Wade had his 14th 20-point effort of the season and he has scored in double figures in 15 straight games.
Heat: At Toronto on Sunday.
Timberwolves: Host Oklahoma City on Sunday.
More AP NBA: https://apnews.com/NBA and https://twitter.com/AP—Sports