ORLANDO, Fla. — Elfrid Payton had 19 points, eight rebounds and eight assists to help the Orlando Magic break a nine-game losing streak with a 102-89 victory over the Detroit Pistons on Thursday night.

Evan Fournier scored 17 points and Aaron Gordon had 14 for Orlando, but it was the Magic’s backup centers who made the difference in the game.

Bismack Biyombo had 12 points and 13 rebounds, and Marresse Speights scored 16 points as replacements for injured starter Nikola Vucevic.

Tobias Harris scored 21 points for Detroit, which had won five of six. Andre Drummond had 17 points and 18 rebounds, and Ish Smith contributed 13 points, seven rebounds and five assists.

The Magic controlled most of the game, but needed a boost from Speights and a strong fourth quarter defensively to win it.

The backup center scored Orlando’s last nine points of the third period to give the home team a 77-71 lead. His 3-pointer on the first possession of the final quarter started a 9-0 run that put the Magic ahead 86-73 with 9:47 left in the game.

Orlando limited Detroit to just 25 percent shooting (5 of 20) in the fourth and forced the Pistons into four turnovers. Orlando outscored Detroit 25-16 in the quarter.

Gordon’s second 3-pointer of the first half gave Orlando a 46-36 lead in the middle of the second quarter, but Detroit responded with a 14-0 run, including eight straight from Smith.

BUCKS 102, TIMBERWOLVES 96: Eric Bledsoe scored 26 points and Giannis Antetokounmpo had a double-double as Milwaukee won at home.

Antetokounmpo had 22 points and 10 rebounds for Milwaukee. John Henson and Khris Middleton each added 14 points.

NOTES

SPURS: Kawhi Leonard was a late scratch from San Antonio’s lineup against the New York Knicks as his playing time remains limited following his return from a quad injury.

Thursday night’s game was the fourth time Leonard has sat out for what the Spurs listed as “return from injury management.”

TIMBERWOLVES: Minnesota point guard Jeff Teague is day to day with a left knee injury.

Teague’s Grade 1 MCL sprain was welcome news for Minnesota, which feared he had a more serious issue. Teague had an MRI on Thursday.