Inspired by another
thread on this forum, I wondered how the experienced hive mind of this forum deals with players who choose violence when a peaceful solution would be possible or even obvious?
I run open world sandbox games. If the players want to murderhobo their way through problems, obstacles, and challenges...that's their choice to make. The world will react accordingly.
Should every action have a consequence?
Emphatically yes. Always. Every action. If it's possible anyone will know about it or witness it or learn about it after the fact, they will react to it...somehow. They may not always know who to blame. But they will still react. And honestly, if an adventuring group passes through an area and they have a reputation for simply murdering anything that gets in their way and robbing the corpses...and you have a pile of corpses stripped to the underoos...it's not difficult to figure out what's happened.
What if it's just shenanigans and a strong response from the DM would derail the campaign, would you say that consequences are consequences, and just rewrite your campaign, which now becomes e.g. a jailbreak?
To me there's no such thing as "derailing" a campaign. Campaigns shouldn't have rails to begin with. The only real way to derail a game is to opt out of adventuring. At that point, retire the characters and have the players make new ones. The DM runs the world...they don't provide a prewritten story for the players to work through...as popular as it is nowadays, it's simply not the DM's job. Whatever story the game has is a result of the players at the table interacting with the world the DM has built. Emergent story. Not preplanned. The DM follows the players wherever they choose to go. If they choose to be wandering murderers and the logical consequences of that is jail time for the PCs, then that's where the game goes. If they want to break out, sure. Figure out how that could work. Logically, without bending or breaking the world or fiction to make it happen. If they can't figure it out, they can make new characters and maybe consider not be murderhobos next time...or better at breaking out of jail.
Or do you look the other way do you don't have to toss out the entire plot?
DM's shouldn't prep plots. The plot involves a beginning, middle, and end. You don't know what the end will be until the players get there. You don't know what the middle will be until the players get there. You don't know what the beginning will be until the players get there. Yes, that's backwards on purpose. The DM doesn't decide what the players or characters will do. So you can't write a plot. You can decide what the monsters and baddies will do unless the PCs intervene. But the PCs are free to nope out of that situation if they want. "But that wastes my prep!" Well, it's your fault for prepping the wrong thing. Prep situations, not plots.
Does it do anything beyond changing the PCs alignment(s)?
If you're running a living, breathing world, yes...absolutely. I've only changed a PCs alignment once. One time. I've been doing this about 40 years now. The PC decided to start torturing a defenseless prisoner who'd surrendered. At first the sheet said Neutral Good, then I changed it to Neutral. Good characters don't do that. Don't @ me.
Do you even actively seek some sort of revenge to teach those roguish players to do better roleplay?
Literally never. It's not your job as the DM to do that. The world reacts according to the PCs' actions. If they don't like the consequences they're facing, they should adjust their behavior. I don't run evil games though. And I'm upfront about that. I never give the monsters or enemies special powers or knowledge the shouldn't or wouldn't have. However much roleplaying and however the players want to roleplay is their choice, not mine.
And what about XP? Do the PCs gain any XP for an encounter that serves no purpose to the storyline, and which might even change the entire plot of the campaign?
I award XP and inspiration for the kinds of things I want to encourage in the players. It changes with each game. I have no storyline to follow, the players tell me what storyline they want to pursue and I follow them. Again, there shouldn't be any plot. Only situations the DM sets up that the players are free to engage with or ignore at their whim. The more "story" or "plot" you try to impose, the less choice the players/characters have.
The missing key here is agency. The players have the agency to choose for themselves. The characters have agency to choose for themselves. Without agency, without meaningful, impactful choices, there's literally no point in having players and pretending you're running a game. If the players/character can't make any real choices, then you're reading them a novel, not running a game.