MIAMI — It wasn’t the shot Anthony Davis wanted.

With less than 2 seconds left in regulation Friday at American Airlines Arena, the Pelicans star forward — who was posting a brilliant stat line in his NBA Christmas Day debut — let fly with a 20-foot jumper that would have beaten the Miami Heat.

It sailed over the rim, and the Heat controlled overtime for a 94-88 win.

“That wasn’t the play,” said Davis, who had 29 points and 15 rebounds. “But I had a good shot. It kind of slipped out of my hand. I kind of lost it when I put it on the floor. It had a chance of going in.”

That Davis’ last look in regulation came off a broken play was a solid summation of the Pelicans’ afternoon.

On a day when New Orleans played some of its best defense of the season — the Heat shot 39.8 percent overall, were 23.1 percent on 3-pointers and committed 18 turnovers — the offense was as discombobulated as ever. At least two times — three by Davis’ count — a Pelicans player was out of position on a play directly following a timeout.

That sort of mistake is “inexcusable,” coach Alvin Gentry said.

One of those players — by his own admission — was guard Tyreke Evans, who was in the wrong spot on the floor out of a timeout with 13.5 seconds to play. That necessitated another timeout 5 seconds later.

“(Gentry) wanted me to be more in the middle” of the floor, Evans said. “We’ve got to do a better job with that. It wasn’t just me.”

Gentry said he didn’t know what led to the confusion.

“We draw everything up and then we duplicate it again, and then the last thing we say is, ‘Does everybody understand where they are?’ ” Gentry said. “And if you say yes, I expect you to get to the right spot. If you say ‘No, I don’t,’ that’s a different story.”

Asked whether any player expressed doubt about where to be coming out of a timeout Friday, Gentry said, “Never. Never.”

“Attention to detail, especially in crucial moments like that, is key for us, something that we’re going to have to grow on,” point guard Jrue Holiday said of the post-timeout confusion. “Obviously this game we did it two or three times and, in a single game, you can’t do that once.”

It wasn’t all the Pelicans (9-20) did wrong.

They shot 40.0 percent and missed 14 of 20 3-point attempts. They were outrebounded 57-45 — Miami’s Hassan Whiteside had 17 rebounds, including 11 in the first quarter to the Pelicans’ 10 — and though New Orleans forced 18 turnovers, it turned them into only two points.

“I think in 28 years in the NBA, I’ve never seen that, where a team can turn the ball over 18 times and you have two points off it,” Gentry said. “And I think that reason that that happened is because, once we had possession of the ball, we just made bad decisions offensively, all night long.”

Those mistakes included turnovers of their own (the Pelicans committed 19, which Miami turned into 13 points) and questionable shots. New Orleans shot contested jumpers. It launched bad shots early in the shot clock.

Davis, who played 50 minutes, scored 20 of his points in the first half, on 18 shots. He took 11 in the second half and overtime combined.

And even with all of its offensive miscues — even without leading until 1:45 remained in the fourth quarter — New Orleans was in the game at the end of regulation.

Ryan Anderson scored 15 of his 18 points after halftime, and Eric Gordon had 10 of his 16, so the Pelicans had their chances. Miami got 30 points and 10 rebounds from Chris Bosh; Dwyane Wade had 19 points.

“We have to find a way to not shoot ourselves in the foot,” Gentry said. “We’ve been doing that a lot lately. I don’t mind losing when a team outplays you, but to just do some of the things that we’re doing, it just doesn’t make sense to me.”

That includes the confusion out of timeouts, a significant problem Friday that Gentry vowed won’t be one going forward, starting with Saturday’s home game against Houston.

“That’s something we’ll get cleared up,” Gentry said. “I guarantee you. In the next week or so, those people will not be in the game.”