Smith helped shoot the Knicks into and then out of the playoffs, having the best season of his career but then struggling through the postseason. The product of nearby New Jersey wanted to stay and the Knicks needed to keep him. They worked out a deal that will pay him about $25 million over four years.

Smith averaged 18.1 points during the regular season, second on the team behind Carmelo Anthony. But he momentarily lost his head and then his shot during the postseason, getting suspended a game for elbowing Jason Terry late in Game 3 of a first-round series against Boston and making only 29 percent of his shots in the final eight playoff games.

Still, it was a strong season for Smith, who showed much more maturity and better shot selection than during most of his career. The Knicks were unlikely to find anyone better with their spending limitations and made re-signing Smith a top priority.

A former teammate of Anthony’s in Denver who developed a good relationship with Knicks coach Mike Woodson, Smith posted a picture of himself in a Knicks jersey in front of the team logo on social media Thursday morning.

Exact terms of the deals won’t be known until July 10, after next season’s salary cap has been set and contracts can be signed.

Prigioni finally came to the NBA this season at 35 after playing in Spain. He played limited minutes as a reserve most of the season but moved into the starting lineup down the stretch and the Knicks took off, going 16-2 with Prigioni among the first five.

The point guard for Argentina’s national team averaged 3.5 points in 78 games. He could make about $6 million over three years.

The Knicks still are trying to hold onto another key player, Chris Copeland, from the team that went 54-28 and won the Knicks’ first Atlantic Division championship since 1994.