Knicks forward OG Anunoby and center Karl-Anthony Towns react in...

Knicks forward OG Anunoby and center Karl-Anthony Towns react in the second half of an NBA game against the Toronto Raptors at Madison Square Garden on Monday. Credit: Kathleen Malone-Van Dyke

A pre-Christmas home game against the skidding Raptors, who were playing their second leg of a back-to-back, hardly was going to say anything substantial about the ceiling of these Knicks. But good teams take care of business against inferior foes in their own building, and the Knicks did just that Monday night.

Karl-Anthony Towns had 31 points, 10 rebounds and seven assists and OG Anunoby — who made his first 11 shots — had 31 points, seven rebounds and four assists in the Knicks’ 139-125 win at Madison Square Garden.

Cam Payne had a season-high 19 points in 15:28 off the bench. Anunoby (13-for-15), Towns (11-for-15) and Payne (7-for-10) shot 31-for-40 between them.

Payne had 11 points and Anunoby nine in a 40-point second quarter, and Anunoby (16) and Towns totaled 27 in a 41-point third quarter. It was the first time the Knicks have had two 40-point quarters in the same game since 1988.

“[OG] was a monster,” Josh Hart said. “Offensively, knocking down shots. He had mid-range, post, threes. He did a little bit of everything. And then obviously on the defensive end, he does what he does.

“It’s great vibes right now, so we just got to make sure we continue to bring that to the game.”

Anunoby, who said he was not aware that he made his first 11 shots, put together one of his best performances of the season against the team with which he spent his first six-plus seasons.

“It’s so weird playing against them,” he said. “But it’s always nice to see those people. I have some really good friends over there. Really great people over there.”

The Knicks (19-10), who led by as many as 33 points at 120-87, won a fourth straight game for the third time this season. They have won 14 of their last 18 and have scored at least 133 points five times in the last 15 games.

“I thought guys were playing together,” coach Tom Thibodeau said. “Creating advantages, hitting the open man. High-assist game. The cutting was good. We’re scoring plenty of points.”

Despite only 12 points and 4-for-13 shooting from Jalen Brunson, who was averaging 25.1 points before Monday, the Knicks led for the final 33:41.

RJ Barrett, the Knicks’ No. 3 overall selection in 2019, had 23 points, six rebounds and six assists for the Raptors (7-23) in his second game back at the Garden since being traded in December 2023. It was the same deal that sent Anunoby to the Knicks.

Scottie Barnes had 24 points for Toronto, which has lost eight games in a row.

The Knicks rattled off a 15-2 run to take a 45-34 lead, and Payne scored 11 points in the first 5:11 of the second quarter to help the Knicks gain separation.

Payne said of his second-quarter impact: “I feel like I need to do that every time, every time I check in. I’m on a one-year deal, so I come out here and play hard as [expletive] every night. Any time I get an opportunity, I just want to make the best of it. So I come out there and play with a lot of confidence.”

Said Brunson, “It’s fun to watch. [Payne] brings the energy, regardless of any situation. I’m not surprised. It happened to us last year, he came into the game in the playoffs and made some big shots when we were playing Philly. So we all know what he’s capable of.”

Said Anunoby: “Cam changed the game.”

What did Hart see in the second-quarter run? “Nothing, really,’’ he said. “I just saw our score go up, and their score didn’t. So that’s about all I remember.”

Notes & quotes: The Knicks shot 59% from the field and 46% from three-point range . . . After the Knicks went ahead by 33 with 10 minutes left, the Raptors got within 133-120 with 2:35 to play. They wound up scoring 43 points in the fourth quarter . . . On Monday morning, the Knicks signed guard Landry Shamet, who was with the team in the preseason and was waived three days before the regular season after suffering a dislocated right shoulder. He made his Knicks debut Monday night with 1:24 left and scored two points.