Why is it the wrong move? There's a couple reasons.
(1) Vivek wants to win now. Vlade wants to win now. Karl wants to win now. And most importantly Cousins and Rondo want to win now. Trading Gay for caproom is a move that a tanking team would make. You're essentially telling Boogie that you're willing to possibly miss out on the playoffs this year for the chance to possibly make the playoffs next year.
(2) $12 million seems like a lot of caproom but I don't think people realize what kinds of contracts are going to get thrown around this offseason. Tristan Thompson got a deal starting at over $14 million with the justification that it wouldn't look like such an awful deal next year (when he's making $15.3 million) because of the salary cap increase. Thompson isn't a defensive anchor, isn't a shotblocker, isn't a guy who can stretch the floor at all and who is averaging around 8 points and 9 rebounds and whose only real calling card is that he's tied for 6th in the league in offensive rebounds.
The capspace the Kings would get from trading Gay for ending contracts would be over $3 million short of being able to afford a Tristan Thompson level talent. This is actually a good offseason to not have a bunch of free agents or to have to fill a lot of holes. Boogie is about to become perhaps the 2nd biggest bargain in the league after Steph Curry. And Gay will be also go from a guy who at one point had an albatross contract to one who is a good deal for the Kings.
A few things:
1. I'm not saying that we need to trade Rudy- just saying that it should be considered if a good deal comes along.
2. I get that we are in win-now mode, I just don't think that Rudy is crucial for that (and I know a lot of people will probably disagree)- I think a lesser player better suited for our needs can give us similar production.
3. I agree about 12 million in caproom not being a lot in this era, and that's Rudy is on a good contract- but extra caproom (even 12 million) together with cap remaining from resigning Rondo could be the difference between not being able to sign any player of significance (because of high prices) and being able to get a guy we need.
4. Boogie is a huge bargain, and we can use that to better our roster- sitting out this year would have us going with the same roster next year which means very limited upside (like I said I think this roster is very unlikely too go past the first round, and it could be harder to get to the playoffs next year consdering we had a lot of "injury luck" this year regarding our opponents).
There's no trade I'd ever make based on PER analysis. Dealing your second leading scorer and two guys off the bench that log a lot of minutes is going to be disruptive. New guys have to learn a system, chemistry has to be developed etc. On paper it may not seem like the Kings would lose a step, but I can pretty much guarantee they'd lose a step, if not several. Which is a precarious place to be if you're trying to claw your way into the postseason this year.
Moreover is Harrison Barnes a massive upgrade over Rudy? Because he turned down an extension from Golden State that started at $18 million. Add in the premium that the Kings normally have to offer to get guys to Sacramento and I'm guessing his deal will start at $20 million or more. I'm not the world's biggest Rudy Gay fan but I'll take Rudy Gay at $12 or $13 million over what $12 or $13 million will buy in the free agent market this offseason.
The Kings are light on draft picks and don't have a ton of caproom. So it will be hard to find ways to improve. It will have to be smart trades (for TALENT), utilizing the picks they do have well and relying on growth from guys like Boogie, Willie, Ben etc and the improvement that comes with experience playing together, something that is often overlooked.
I don't do the trade because of PER analysis, it was just something I thought was worth mentioning.
Rudy is a scorer for us but he is not a great fit in our system, our team is actually worse this year with him on the floor (-1.8), Casspi is a better fit for us (+2.2).
Marco has been flat out bad this year and though I think KK is a very nice player he doesn't work well with DMC or with WCS (evident by his -4.0) making him a luxury we don't need.
Harrison Barnes can shoot and he is a better defender, I don't know about talent but that's something I feel we need, I think he is a far better fit next too DMC and Rondo than Gay is- but there are a lot more guys of that type out there this year.
That trade will give us 24 million more and a guy we need on a rookie contract, you are looking at it as "Gay is a bargain in this current market" which is true, but a narrow way to look at things imo- with this trade you are creating far more space to shape the team and another max level contract room along with Rondo, that's HUGE.
Like you said we can't get better through the draft (we don't have our pick this year) and it's highly unlikely we can make a change with our capspace. and though there is some potential for improvement among our existing players (mostly Ben and Willie), I doubt it will be enough to turn us into anything more than a 7-8th seed contender (which is much better than what we were but still limited).
We are also pretty limited when it comes to trades:
Despite the fact Gay is a good scorer, on a good contract, and some say a top 10 SF, his trade value shouldn't be high- he has a bad rep for is ability to play in a winning team (mostly because of his defnse and shooting), tanking teams don't need him and the contending teams that'll want him won't send talent in return. KK is a nice center but the league is full of nice centers right now so I don't see him netting anything of great value.
Trading for capspace might be the most realistic way for us to take a leap forward, I'll end this by saying I'm far from decided on this kind of deal for all the reasons you mentioned and the chance it can hurt team chemistry- but I wouldn't take it off the table, and I think it definitely make (atleast) some sense.