Greivis Vasquez capped a 25-point, nine-assist performance by hitting a running floater off the backboard with 12 seconds left, and the New Orleans Hornets beat the Detroit Pistons 100-95 on Friday night to snap a two-game skid.

Eric Gordon added 21 points and Ryan Anderson 19 points and 13 rebounds for the Hornets, who were short-handed in the frontcourt with starting forward Anthony Davis sitting out his second straight game because of a sprained left shoulder.

New Orleans native Greg Monroe had 27 points and 10 rebounds for Detroit, while Brandon Knight added 22 points, including a 3-pointer that tied the score at 91.

Vasquez’s final basket made it 98-95, and Rodney Stuckey missed a 3-point attempt that could have tied it in the final seconds.

New Orleans closed the third quarter with an 8-0 run, capped by Anderson’s second 3, to take a 74-69 lead.

New Orleans was still ahead 91-84 when Gordon scored inside, but Detroit responded with a 9-0 run that Knight began with a driving layup. Jason Maxiell then dunked, Knight came back with his tying 3 and Monroe dunked to give the Pistons a 93-91 lead with 1:58 left.

Vasquez then hit two free throws to tie it, Gordon added another free throw and then Anderson used a perimeter fake to set up a driving layup that made it 96-93. Maxiell had a chance to tie it when he dunked as he was fouled, but he missed the free throw, allowing Vasquez to put New Orleans up by three again with his late floater.