I had something like that happen. I had to rewrite the whole story on the fly and kept hinting at the big, important mystery that they missed out because they killed the people necessary for the initial hook of the quest.
It's a moment to re-establish the general idea of the adventure out of character. Trying to one-up murderhobos with fictional consequences is sure to spiral into pettiness and end up miserable for everyone involved.
I was a player in a campaign where two of the other players just full-on sprinted past every sign post the (Pathfinder) GM threw up saying, "This character is here to give quests. He is much higher level than you. Don't attack him. He will slaughter you."
They pulled out their weapons and made to attack the guy and my CN character was like, "You have fun with that. I don't want to die today." The quest giver and our other party member tried to talk them out of it for a couple rounds AFTER they started attacking (and doing no damage, naturally). The NPC then started using non-lethal spells to try to defuse the situation. A couple rounds of that and the GM finally gave up went hostile. Two or three AoE attacks later and both characters were gone.
They rolled new characters, but I didn't last much longer in that campaign.
Set bounties on them. Put up wanted posters in major cities. Now they can no longer find important NPCs and they are constantly attacked by adventuring parties and mercenaries.
One of the things I like about the CofD games like Mage is it has a mechanical tracker for doing vile stuff. "Sure, you can curse him to vomit forever but that's going to call for a Wisdom check." Losing wisdom means you're worse at containing spell miscasts. Uncontained spell paradoxes will ruin your day. And hitting wisdom 0 means the character is unplayable.
I've stopped a lot of nonsense with "that'll be a wisdom check, if you're sure you want to do that"
Yeah, I remember playing D&D in high school. If you don't have a lot of maturity, it's easy to fall into violent power fantasies that the freedom of a TRPG offers versus a CRPG.
This is why I'm really glad for modern session 0 agendas and safety tools to set expectations and keep people on the same page.
but everyone including the DM needs to agree to it beforehand.
Exactly, it can be a lot of fun if everyone is on board. So many great ttrpg memories have come from that kind of chaos, but they're only good memories because everyone at the table consented to join the chaos.
"The Quest giver speaks some unholy last words, your entire party faints, a unknown amount of time passed, your party wakes up in some kind of dark and cold cave, you can't find your belongings, you just have the clothes you wore last time you remember, one party member finds a magic torch, you can see you are in a dungeon, from the color of the stone you estimated to be pretty deep inside it..."
I actually kind of embrace the players doing whatever they want, so long as it's not some way to harass other players or the DM. If they're doing something to deliberately ruin the game, that's not acceptable. If they're doing something the DM didn't expect or account for, that's just the game baybee. It be how it is