Shooting guard Luka Doncic stunned American Airlines Center when he made a 36-foot three-pointer to beat the shot clock to blunt a late Sacramento rally and finished with 23 points in the Dallas Mavericks’ 105-99 victory over the Kings on Sunday.

With 4:53 remaining, the Kings reduced a 12-point deficit to 92-89. Doncic scored a 3-pointer from the rim of the centre-court logo with roughly two seconds left on the 24-second clock after dribbling the ball off a defender’s foot to get back behind the midcourt line.

Also read: NBA: Barrett scores 35 points, help New York Knicks beat New Orleans Pelicans, 123-117

“I’m confident in all my 3s,” said Doncic, who missed his other six attempts from behind the line, according to Associated Press inputs. “That shot goes in, but then all my normal shots can’t go in. I’ve got to work on those normal shots.”

“That was a big-time shot,” Mavericks coach Jason Kidd said. “I think we all know he has that type of range.”

Meanwhile, Tim Hardaway Jr. amassed 16 points to help the Mavericks rebound from a 31-point loss in Denver on Friday night. Dallas lost three meetings with Sacramento last season.

Also read: NBA champs Milwaukee Bucks to visit the White House on November 8

Richaun Holmes had 22 points and 13 rebounds for Sacramento, and Harrison Barnes added 15 points. The Kings lost for the first time in four road games this season.

Doncic shot 10 for 21 from the floor and had eight rebounds and 10 assists. The Mavericks were 12 for 37 behind the arc, and the Kings 7 for 36.

Also read: NBA fines Trae Young $15,000 for making contact with referee

Maxi Kleber made his first start of the season for Dallas in place of Kristaps Porzingis, who missed his third straight game with lower back tightness. But Kleber — who had seven points and five rebounds in seven minutes, strained his back late in the first quarter and didn’t return.

The Kings will next visit the Utah Jazz on Tuesday night while Doncic and co. host Miami Heats on the same day.

With inputs from the Associated Press