Knicks guard Dennis Smith Jr. goes in for a basket...

Knicks guard Dennis Smith Jr. goes in for a basket as Hawks guard Kevin Huerter watches during the first half on Thursday in Atlanta. Credit: AP/John Bazemore

ATLANTA — The losses had dated to Jan. 4, a stretch of 18 straight games. And at this point, a win wasn’t going to make much difference, other than giving the downtrodden Knicks the chance to retreat to the All-Star break with the gloom of a franchise-record losing streak behind them.

And as they departed — with most of the team bound for a week-long vacation, no one in the All-Star Game and only Kevin Knox and Dennis Smith Jr. heading to Charlotte for any part of the festivities — they left relieved about ending the futility with a 106-91 win over the Atlanta Hawks.

With the Knicks having lost 26 of 27 and 31 of 33 entering the game, Knox described the importance of the victory. “Yeah, it’s great going to All-Star Weekend with a win,” he said, at which point the lights went out in the locker room.

Teammates laughed as the rookie waited in the dark before adding, “I’m going to go out there and just have fun, get ready to get back home and have some rest.”

“It was great, but it wasn’t overreaction,” coach David Fizdale said. “I think they know that we’ve been beating on the door and beating on the door. I think the gratification was getting over the hump finally with our defense.”

“Super-satisfying,” said Smith (19 points), who joined the Knicks 12 games into the streak. “We came in, me and [DeAndre Jordan] came into a situation with a team on a losing streak and obviously it was up to us to change it. It took us a little minute to do it, but now we finally turned it around. We’ll try to get on the opposite side of that hill, start moving in a good direction.”

Even if the Knicks (11-47) refuse to admit to tanking, refuse to point to the NBA Draft Lottery and the prospect of fitting Zion Williamson for a uniform, the numbers are still overwhelming.

Hawks guard Kent Bazemore drives against Knicks guard Allonzo Trier...

Hawks guard Kent Bazemore drives against Knicks guard Allonzo Trier during the first half on Thursday, Feb. 14, 2019, in Atlanta. Credit: AP/John Bazemore

The win moved the Knicks out of the NBA’s bottom spot — they’re now a half-game ahead of the Phoenix Suns in the standings — but the league’s three worst teams will have an equal 14 percent chance of winning the top pick.

 The Knicks have had the Hawks' number, beating them for a third time in four meetings this season.

The Knicks opened a 14-0 lead, with the Hawks going 4:34 before finally getting on the board when John Collins tipped in a missed shot. The Knicks built the lead to 15 by the end of the quarter as Atlanta shot 6-for-29 — 0-for-9 from beyond the arc.

That lead faded as the Hawks tied the score at 47 on Amari Spellman’s three-pointer with 1:27 remaining in the first half. But even if the lead disappeared, the Knicks never fell behind.

New York Knicks guard Dennis Smith Jr. (5) goes in...

New York Knicks guard Dennis Smith Jr. (5) goes in for a basket asA tlanta Hawks guard Kevin Huerter (3) watches during the first half of an NBA basketball game Thursday, Feb. 14, 2019, in Atlanta. (AP Photo/John Bazemore) Credit: AP/John Bazemore

Again adjusting the starting lineup, Fizdale inserted Luke Kornet and Damyean Dotson alongside Smith, Knox and Jordan. The move didn’t exactly work miracles, even if the team got off to a solid start.

Kornet shot 3-for-16, but fellow Vanderbilt and Westchester Knicks product John Jenkins (14 points) came off the bench to provide a lift. He hit five of his first six shots after not playing at all in Wednesday night’s loss to Philadelphia.

Kadeem Allen (14 points, nine assists), also a recent call-up from Westchester, hit a three-pointer with the shot clock running down and 5:20 left to push the lead to 97-85.

Jordan added 10 points, 13 rebounds and three blocked shots. Dewayne Dedmon had 21 points for the Hawks, who had 38 points in the second quarter and 53 in the other three quarters.

Newsday LogoSUBSCRIBEUnlimited Digital AccessOnly 25¢for 5 months
ACT NOWSALE ENDS SOON | CANCEL ANYTIME