MILWAUKEE -- All Khris Middleton needed to get going on offense was to create a little space.
Once Middleton's first couple shots started falling, he was tough to stop , especially in front of a friendly crowd in a tight game in the fourth quarter.
Middleton scored 12 of his 31 points in the final 4:38, Giannis Antetokounmpo had 27 points and 11 rebounds, and the Milwaukee Bucks rallied for a 109-102 win over the last-place Dallas Mavericks on Friday night.
"Just got into a rhythm really. I was able to create a little space, was able to catch and shoot 3s ... find a rhythm, find an open shot," Middleton said.
Middleton finished 10 of 18 from the field, including 5 of 6 in the fourth. The 6-foot-8 forward is a tough matchup because of his length and shooting ability, especially when paired with the athletic Antetokounmpo in the frontcourt.
Eric Bledsoe added 24 points for the Bucks, who erased an 11-point deficit late in the third quarter to pick up their fifth win in six games.
The Bucks then turned up the defensive pressure during a chippy final few minutes, highlighted by Middleton's four-point play sandwiched between two Dallas turnovers.
"A lot of his points down the stretch came off situations where we weren't executing well offensively and gave them some downhill momentum," Mavs coach Rick Carlisle said.
But the worst team in the Western Conference didn't wither on the road against an East contender. The Mavericks played the Bucks tough until the end, as they did in a loss to the Boston Celtics on Wednesday.
Wesley Matthews had a season-high 29 points to lead Dallas. He scored 15 in the first half on 6 of 7 shooting, including 3 of 4 from 3-point range, to give the Mavericks a 54-49 lead going into the locker room.
Shooting 6 of 13 (46 percent) from beyond the arc in the half, the Mavs tried to follow a formula similar to their 32-point win over Milwaukee on Nov. 18, when they shot 19 of 38 (50 percent) from 3-point range.
This time, the Bucks answered with clutch jumpers and improved defense.
They used a 12-0 late in the third quarter sparked by two 3s from Middleton and the playmaking ability of Malcolm Brogdon to take a 77-76 lead after looking lethargic for much of the game.
"In that first half we kind of fell into the trap of them walking the ball up and kind of were just going through the motions," coach Jason Kidd said.