Surrounded by reporters the day after the NBA announced a blockbuster new television deal in October, Oklahoma City Thunder forward Kevin Durant contemplated the maximum-salary rule that governs his compensation and that of his superstar peers.

“Look at it like this,” Durant said. “Kobe Bryant brings in a lot of money to Los Angeles, that downtown area. People go to watch the Lakers. Clippers are getting up there — Chris Paul, Blake Griffin and those guys are bringing in a lot of money as well. Look at Cleveland, look at Miami when LeBron [James] was there. These guys are worth more than what they are making because of the amount of money they bring to that area.”

NBA players do not get paid what they’re actually worth. Really young? Really good? Sorry — for you, the market isn’t truly an open one. Analysts — and increasingly players such as Durant and Bryant — can tell you that the maximum-contract rule suppresses the salaries of superstars, that inexperienced players are paid less than their contributions warrant, and that as a result, the NBA’s middle class is paid far too much.

In recent years, however, that popular notion appears to have been wrong. I built a model measuring how much NBA teams paid for their players’ wins above replacement (WAR), and it shows that the league has changed. During the 2014-15 season, the middle class was, in fact, paid far less for its production than max-contract players, accelerating a trend that began two seasons earlier. In other words, the role players were suddenly steals.

But if this offseason is any indication, max players are the bargains once again. Forgive me for sounding like a bad Internet headline — but you are not going to believe how underpaid Kawhi Leonard is, despite his new max contract. The same salary cap spike that’s made this free-agency period so wacky is shifting what the league’s players are worth yet again.

But before we dwell on the future, let’s rummage through the past.

For most of the past decade, the hoary aphorisms about which players were relatively cheap (and which were relatively exorbitant) held true. From the 1999-2000 season through the 2010-11 one, players on rookie contracts (think Derrick Rose when he won the MVP award in 2010-11) generated 23 percent of the league’s WAR but were paid only 12 percent of the league’s money. Players on maximum contracts (such as James and Bryant) were also shortchanged, generating 24 percent of the wins but making 22 percent of the money.

And the rest of the league — the players I’m calling “middle-class” because they’re neither rookies nor max players (and therefore their earning power isn’t systematically capped) — gobbled up the surplus, making 65 percent of the money despite generating 52 percent of the wins.

If the market were truly efficient, all the players would be paid the same for each win; there wouldn’t be a difference between any of the curves in the chart above — they’d just be one big, fat, overlapping line, ebbing and flowing in unison. Instead, the prices per win for players are clearly stratified by type of contract, particularly during the period before the league installed a new collective bargaining agreement for the 2011-12 season.

Recently, though, a shift has taken place. Young players are still drastically underpaid, of course; the numbers in the chart aren’t adjusted for increases to the NBA’s salary cap, making the young players’ relatively flat line striking, given that the cap nearly doubled between 1999-2000 and 2014-15. But the price of a middle-class win took a downward turn sometime around the 2008-09 or 2009-10 seasons after years of shadowing the max-salary line.

Since then, buying a win from a max-salary player has become more expensive than ever before. While the salary cap rose by 8.7 percent between 2011-12 and 2014-15, the cost of a max player’s wins rose by 39 percent. The per-win price of a middle-class player in that time fell by 15 percent. The middle-class players were the hidden gems.

Max deals have always come with risk: Between the 1999 and 2005 offseasons, 57 percent of max contracts weren’t worth it, failing to deliver more value than the teams paid for. But during that era, enough max players succeeded — and tended to be home runs when they did — that on balance, they represented a better deal than middle-class players. After 2005, though, max players became more dangerous to invest in: Only 14 percent of all max deals since then have delivered a positive return. By the late 2000s, when those contracts were in full swing, max players were collectively providing less bang for the buck than the middle class — a first since the max salary was instituted in 1999.

This was a significant development because it suggested a path to contention that didn’t involve superstars (a rarity in NBA history). Traditionally, the market for mid-level players has been a place for also-rans looking for scraps after the hyenas have had their way with the max-contract types. That dynamic reinforced the NBA’s competitive balance problem by effectively forcing smaller-market teams to spend more for their talent, on a per-win basis, than the league did overall. Any mechanism that made it cheaper for those types of teams to buy talent, though, stood to give the NBA a much-needed injection of parity.

But an unprecedented rise in the salary cap might end all this. The early indications are that how much a million bucks can buy in each salary class will be upended once again. Just when the guidelines of a player’s worth were beginning to shift in an interesting (and more competitive) direction, the rising cap may bring the old wisdom all the way back around to being right again.

To help model this and other matters of NBA interest, FiveThirtyEight editor-in-chief Nate Silver and I have been skunkworking a little model around here that will (theoretically, hopefully, god-willing) begin to do for basketball what PECOTA did for baseball. Using a player’s advanced metrics and his statistical tendencies, it can project a player’s development into the future by comparing him to similar players from the past. We call it CARMELO.

Using the beta version of CARMELO to analyze this summer’s free-agent signings, I found that 10 of the 16 maximum-contract signees (as of July 12) project to bring a team a positive return on investment. As a group, it looks like they’ll be underpaid by an average of $5.6 million per year. (Leonard lords above them all: He’s projected to bring $26.9 million of extra value to the Spurs every year. ) That’s quite a bit bigger than the average non-max signee of the summer, who thus far projects to bring his team just $850,000 of extra value per season.

In other words, the max player is once again a far better deal than his middle-class peers.

The cheapest way to build a great team in today’s NBA remains to concentrate on young players still on their rookie contracts. And it’s worth noting that the long-range implications of the league’s sudden salary cap explosion won’t be fully understood for years. But although basketball’s long-understood rules of value seemed on the verge of disruption in recent seasons, this summer offered an early peek into how teams and players will behave during the coming boom years, and it suggests that everything old is new again.

See all the free-agent signings (through July 12), and whether the players will be underpaid or overpaid here: