AUBURN HILLS, Mich. (AP) Josh Smith knows that his shooting slump is hurting the Detroit Pistons.
Friday, he found other ways to help them win.
Smith, who is 7-of-31 shooting in the last two games, had key plays on both ends in the final 20 seconds, allowing the Pistons to escape with a 98-95 victory over the Milwaukee Bucks.
''I'm struggling to put the ball in the basket, but winning isn't only about making shots,'' he said. ''I know that I've still got intangibles that I can bring to the floor.''
With the Pistons up 95-93, Kentavious Caldwell-Pope badly missed a five-footer, but Smith alertly grabbed the rebound and put it in to give the Pistons a four-point edge with 15.1 seconds to go.
Smith then stripped Brandon Knight, allowing Detroit to clinch the game from the line.
''I give Josh a ton of credit for playing well despite the way he's struggling with his shot,'' Pistons coach Stan Van Gundy said. ''He's had a really rough time, but he gets the game-winning shot and the steal. Those were the two biggest plays of the game.''
Kentavious Caldwell-Pope had 19 points, including a key 3-pointer to halt a Milwaukee rally in the final minutes.
''The reason that KCP has the confidence to make those shots is that he's prepared,'' Van Gundy said. ''That's how you build confidence to take shots - you shoot hundreds of balls a day and you watch them go through the net.''
Jabari Parker led the Bucks with 18 points, while former Piston Brandon Knight added 17 and nine assists.
''We didn't win, so I didn't do enough,'' said Parker, who was playing just his sixth NBA game. ''I'd rather have a game where I score four points and we win than a game like this one.''
The Pistons led for the entire first half, looking like they were getting a grasp on Van Gundy's offense. He started his big frontcourt - Smith, Andre Drummond and Greg Monroe - but foul trouble meant that the three were rarely on the court together in the half, avoiding their usual offensive-spacing issues.
Detroit got away from that after halftime, taking bad shots and turning the ball over. Milwaukee took advantage with its first lead late in the third, thanks to a 3-pointer from Knight, but the player he was traded for - Jennings - replied with two of his own.
The Pistons regained the advantage in the fourth, as the Bucks struggled to find scoring from anyone other than Parker and Knight.
''We have a lot of young guys, so this is going to be a good learning experience for them,'' Bucks coach Jason Kidd said. ''They understand that when they make a mistake, they have to keep playing, but we've got to be able to execute on both ends to win.''
Back-to-back driving layups by Giannis Anteokoumpo and Parker pulled Milwaukee within 90-87 with 2:48 left, but Caldwell-Pope answered with a 3-pointer and the Pistons got enough stops to hold on.
Bucks: Johnny O'Bryant still hasn't made his NBA debut after sustaining a right knee injury during a preseason game at the Palace. . Khris Middleton, also acquired by the Bucks in the Jennings trade, did not play. He had been averaging 10.8 points in 26 minutes in Milwaukee's first five games, but Jason Kidd chose to give his minutes to Kendall Marshall.
Pistons: Smith, who shot just 26.4 percent on 3-pointers last season, is 0 for 9 through Detroit's first five games. . Van Gundy said before the season that he planned to limit the minutes that Smith, Drummond and Monroe played together - they were ineffective last season - but he's now started them in the last three games to get more defense and rebounding.
FINDING THE OUTSIDE SHOT: On the first night of Detroit's four-game homestand, it missed 16 of 17 3-pointers in a loss to Brooklyn. In the next two games - three-point wins over the Knicks and Bucks - the Pistons have shot 47.8 percent from behind the arc.
HANGING ON TO THE BALL: Parker and Knight combined for 35 points on 25 field-goal attempts, but turned the ball over nine times, including three in the fourth quarter.
Bucks: Host Grizzlies on Saturday.
Pistons: Host Jazz on Sunday.