NBA

Knicks defeat Bucks, have control of playoff spot

MILWAUKEE — It looks like the Knicks still will be playing ball in late April, and Carmelo Anthony and J.R. Smith may be the scoring tandem that gives them a puncher’s chance in the playoffs.

The Knicks got great shot-making from Anthony and one brilliant moment from Smith, who hit the go-ahead 3-pointer with 1:04 left, as they held off the pesky Bucks in a roller-coaster game that may have secured their playoff spot.

On a night the Knicks could have fallen out of playoff position, the Knicks survived a 111-107 shootout as Anthony scored 32 points and a struggling Smith hit two late bombs to finish with 14 off the bench, quieting the Bradley Center.

The Knicks (30-28), who held Milwaukee to 19 points in the fourth quarter, moved two games ahead of the ninth-place Bucks and probably will own the tiebreaker with eight games remaining. The Knicks and Bucks split the four-game season series, but the Knicks have a better record against the East (23-18 to 21-19).

The Knicks are in eighth place and would face the Bulls if the season ended today. They trail the Sixers by one game.

“We feel good about ourselves, we feel good about this win, especially a road win against a team behind us,’’ said Anthony, who shook off foul trouble and sore hand to shoot 13-of-26.

The Knicks offense, so decrepit in the loss to the Bulls the night before, lit up Brew City early, hitting 14 of their first 16 shots but lost their 14-point first-quarter lead and needed to mount a fourth-quarter rally from eight points down in the final eight minutes.

“This is a game we had to have,” coach Mike Woodson said. “I needed to get this game.”

Center Tyson Chandler had a big night with 19 points and 11 rebounds and rookie guard Iman Shumpert was great on both ends, with 16 points, six rebounds, five assists and three steals. Despite their heroics, the Knicks still wouldn’t have won unless Smith erased his miserable night. Smith posted his most noteworthy shot in Milwaukee since his raunchy Twitter photo last month drew an $25,000 NBA fine.

You take the good and the bad with the Freehold, N.J., product. Smith was 3-of-9 early in the fourth quarter and committed two silly fouls on Mike Dunleavy from the 3-point line. But Woodson stuck with him.

“I need J.R., I am a big believer in J.R.,’’ said Woodson, who moved to 12-4. “I’m in his corner. I’m doing everything to have him be successful because I think he has the talent, and he showed it at the end of the game.’’

Anthony and Smith ultimately outdid Bucks guards Monta Ellis (35 points) and Brandon Jennings (22).

The red-hot Ellis drilled the 3-pointer for a 105-103 lead with 1:45 left before Anthony went to work, scoring on a turnaround jumper to tie the score at 105.

“Just a total, all-around great game for [Anthony],’’ Woodson said. “He did everything we needed him to do.’’

An offensive putback by Luc Richard Mbah a Moute put the Bucks ahead 107-105. Then Smith received the ball on the left wing after a two-man pick-and-roll with Anthony and hit a monster 3-pointer to put the Knicks up for good at 108-107 with 1:04 left. Woodson said his coaching staff has been begging him to get Smith and Anthony involved in the two-man game as a staple.

“Over and over, he keeps showing his confidence in me,’’ Smith said. “Coach gives confidence to keep shooting no matter how many I miss. My teammates keep telling me to keep shooting and shooting even if I miss 30 in a row.’’

Anthony has seen Smith rise from the dead before, when they were teammates in Denver.

“That’s why he’s J.R. Smith,’’ Anthony said. “He’s never not going to take that shot. I’ve been with J.R. seven year now. I know when he wants to take that shot, when he feels he’s going to make that shot and he felt he was going to make that shot.’’

The Bucks had three chances on the next possession, but they couldn’t connect.

“The way we responded being down eight coming down the stretch, we buckled down on the defensive end and won this game,’’ Anthony said. “I love these moments, fighting for a playoff spot with the playoffs right around the corner — a game that you have to win and being a part of that.’’

marc.bermans@nypost.com